Skip to content

Commit

Permalink
update spec
Browse files Browse the repository at this point in the history
  • Loading branch information
raykrishardi committed Sep 20, 2024
1 parent 48a328e commit 282bdab
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions spec/ecs_service_event_lambda_target_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
end

it "to have property Targets" do
expect(resource["Properties"]["Targets"]).to eq([{"Arn"=>"arn:aws:lambda:ap-southeast-2:123456789012:function:hello-world", "Id"=>{"Fn::Sub"=>"${EnvironmentName}-HelloWorldLambda"}, "Input"=>{"Fn::Sub"=>"{\"target_recycle_cluster_arn\":\"arn:aws:ecs:ap-southeast-2:123456789012:cluster/cluster1\",\"target_recycle_service_name\":\"nginx\",\"target_recycle_service_warmup_period_second\":0}"}, "DeadLetterConfig"=>{"Arn"=>"arn:aws:sqs:ap-southeast-2:123456789012:dlq"}}])
expect(resource["Properties"]["Targets"]).to eq([{"Arn"=>{"Fn::Sub"=>"arn:aws:lambda:ap-southeast-2:123456789012:function:hello-world"}, "Id"=>{"Fn::Sub"=>"${EnvironmentName}-HelloWorldLambda"}, "Input"=>{"Fn::Sub"=>"{\"target_recycle_cluster_arn\":\"arn:aws:ecs:ap-southeast-2:123456789012:cluster/cluster1\",\"target_recycle_service_name\":\"nginx\",\"target_recycle_service_warmup_period_second\":0}"}, "DeadLetterConfig"=>{"Arn"=>{"Fn::Sub"=>"arn:aws:sqs:ap-southeast-2:123456789012:dlq"}}}])
end

end
Expand All @@ -46,7 +46,7 @@
end

it "to have property FunctionName" do
expect(resource["Properties"]["FunctionName"]).to eq("arn:aws:lambda:ap-southeast-2:123456789012:function:hello-world")
expect(resource["Properties"]["FunctionName"]).to eq({"Fn::Sub"=>"arn:aws:lambda:ap-southeast-2:123456789012:function:hello-world"})
end

it "to have property Action" do
Expand Down
4 changes: 2 additions & 2 deletions spec/ecs_service_schedule_lambda_target_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
end

it "to have property Targets" do
expect(resource["Properties"]["Targets"]).to eq([{"Arn"=>"arn:aws:lambda:ap-southeast-2:123456789012:function:hello-world", "Id"=>{"Fn::Sub"=>"${EnvironmentName}-HelloWorldLambda"}, "Input"=>{"Fn::Sub"=>"{\"target_recycle_cluster_arn\":\"arn:aws:ecs:ap-southeast-2:123456789012:cluster/cluster1\",\"target_recycle_service_name\":\"nginx\",\"target_recycle_service_warmup_period_second\":0}"}, "DeadLetterConfig"=>{"Arn"=>"arn:aws:sqs:ap-southeast-2:123456789012:dlq"}}])
expect(resource["Properties"]["Targets"]).to eq([{"Arn"=>{"Fn::Sub"=>"arn:aws:lambda:ap-southeast-2:123456789012:function:hello-world"}, "Id"=>{"Fn::Sub"=>"${EnvironmentName}-HelloWorldLambda"}, "Input"=>{"Fn::Sub"=>"{\"target_recycle_cluster_arn\":\"arn:aws:ecs:ap-southeast-2:123456789012:cluster/cluster1\",\"target_recycle_service_name\":\"nginx\",\"target_recycle_service_warmup_period_second\":0}"}, "DeadLetterConfig"=>{"Arn"=>{"Fn::Sub"=>"arn:aws:sqs:ap-southeast-2:123456789012:dlq"}}}])
end

end
Expand All @@ -46,7 +46,7 @@
end

it "to have property FunctionName" do
expect(resource["Properties"]["FunctionName"]).to eq("arn:aws:lambda:ap-southeast-2:123456789012:function:hello-world")
expect(resource["Properties"]["FunctionName"]).to eq({"Fn::Sub"=>"arn:aws:lambda:ap-southeast-2:123456789012:function:hello-world"})
end

it "to have property Action" do
Expand Down

0 comments on commit 282bdab

Please sign in to comment.