1
0
Fork 0
mirror of https://github.com/fog/fog.git synced 2022-11-09 13:51:43 -05:00

Start SNS tests.

This commit is contained in:
phiggins 2011-03-17 22:44:28 -07:00 committed by geemus
parent 542cffe5b0
commit 9c78523e5e
2 changed files with 37 additions and 0 deletions

View file

@ -0,0 +1,9 @@
class AWS
module SNS
module Formats
BASIC = {
'RequestId' => String
}
end
end
end

View file

@ -0,0 +1,28 @@
Shindo.tests('AWS::SES | topic lifecycle tests', ['aws', 'sns']) do
tests('success') do
tests("#create_topic('TopicArn' => 'example-topic')").formats(AWS::SNS::Formats::BASIC.merge('TopicArn' => String)) do
pending if Fog.mocking?
body = AWS[:sns].create_topic('Name' => 'example-topic').body
@topic_arn = body["TopicArn"]
body
end
tests("#list_topics").formats(AWS::SNS::Formats::BASIC.merge('Topics' => [String])) do
pending if Fog.mocking?
AWS[:sns].list_topics.body
end
tests("#delete_topic('TopicArn' => 'example-topic')").formats(AWS::SNS::Formats::BASIC) do
pending if Fog.mocking?
AWS[:sns].delete_topic('TopicArn' => @topic_arn).body
end
end
tests('failure') do
end
end