mirror of
https://github.com/fog/fog.git
synced 2022-11-09 13:51:43 -05:00
commit
d3d644460b
3 changed files with 18 additions and 6 deletions
|
@ -40,7 +40,16 @@ module Fog
|
|||
class Mock
|
||||
|
||||
def resume_processes(auto_scaling_group_name, options = {})
|
||||
Fog::Mock.not_implemented
|
||||
unless self.data[:auto_scaling_groups].has_key?(auto_scaling_group_name)
|
||||
raise Fog::AWS::AutoScaling::ValidationError.new("AutoScalingGroup name not found - no such group: #{auto_scaling_group_name}")
|
||||
end
|
||||
|
||||
response = Excon::Response.new
|
||||
response.status = 200
|
||||
response.body = {
|
||||
'ResponseMetadata' => { 'RequestId' => Fog::AWS::Mock.request_id }
|
||||
}
|
||||
response
|
||||
end
|
||||
|
||||
end
|
||||
|
|
|
@ -44,10 +44,15 @@ module Fog
|
|||
|
||||
def suspend_processes(auto_scaling_group_name, options = {})
|
||||
unless self.data[:auto_scaling_groups].has_key?(auto_scaling_group_name)
|
||||
raise Fog::AWS::AutoScaling::ValidationError.new('AutoScalingGroup name not found - null')
|
||||
raise Fog::AWS::AutoScaling::ValidationError.new("AutoScalingGroup name not found - no such group: #{auto_scaling_group_name}")
|
||||
end
|
||||
|
||||
Fog::Mock.not_implemented
|
||||
response = Excon::Response.new
|
||||
response.status = 200
|
||||
response.body = {
|
||||
'ResponseMetadata' => { 'RequestId' => Fog::AWS::Mock.request_id }
|
||||
}
|
||||
response
|
||||
end
|
||||
|
||||
end
|
||||
|
|
|
@ -1,8 +1,6 @@
|
|||
Shindo.tests('AWS::AutoScaling | model_tests', ['aws', 'auto_scaling']) do
|
||||
|
||||
tests('success') do
|
||||
pending if Fog.mocking?
|
||||
|
||||
lc = nil
|
||||
lc_id = 'fog-model-lc'
|
||||
|
||||
|
@ -62,7 +60,7 @@ Shindo.tests('AWS::AutoScaling | model_tests', ['aws', 'auto_scaling']) do
|
|||
|
||||
tests('suspend processes') do
|
||||
asg.suspend_processes()
|
||||
#tests('processes suspended').returns([]) { asg.suspended_processes }
|
||||
tests('processes suspended').returns([]) { asg.suspended_processes }
|
||||
end
|
||||
|
||||
tests('resume processes') do
|
||||
|
|
Loading…
Reference in a new issue