Permalink
Browse files

AWS::RDS::DBInstance#snapshots now uses the correct filter.

  • Loading branch information...
1 parent 90c9dca commit c34c6e8ed0453798b317204afc3f8b7c5c676d65 @trevorrowe trevorrowe committed Nov 1, 2012
Showing with 62 additions and 1 deletion.
  1. +43 −0 features/rds/client.feature
  2. +18 −0 features/rds/step_definitions/rds.rb
  3. +1 −1 lib/aws/rds/db_instance.rb
@@ -0,0 +1,43 @@
+
+# Copyright 2011-2012 Amazon.com, Inc. or its affiliates. All Rights Reserved.
+#
+# Licensed under the Apache License, Version 2.0 (the "License"). You
+# may not use this file except in compliance with the License. A copy of
+# the License is located at
+#
+# http://aws.amazon.com/apache2.0/
+#
+# or in the "license" file accompanying this file. This file is
+# distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF
+# ANY KIND, either express or implied. See the License for the specific
+# language governing permissions and limitations under the License.
+
+# language: en
+@rds @client
+Feature: Route 53 Client
+
+ Scenario: CreateHostedZone
+ When I call #create_hosted_zone on the client
+ Then a request should have been made like:
+ | TYPE | NAME | VALUE |
+ | http | verb | POST |
+ | http | uri | /2012-02-29/hostedzone |
+
+ Scenario: DeleteHostedZone
+ Given I call #create_hosted_zone on the client
+ When I call #delete_hosted_zone on the client with the zone id
+ Then #get_hosted_zone should raise "AWS::Route53::Errors::NoSuchHostedZone"
+
+ Scenario: GetHostedZone
+ Given I call #create_hosted_zone on the client
+ When I call #get_hosted_zone on the client with the zone id
+ Then a request should have been made like:
+ | TYPE | NAME | VALUE |
+ | http | verb | GET |
+ | http | uri_match | ^\/2012-02-29\/hostedzone\/.+ |
+
+ Scenario: ListHostedZones
+ Given I call #create_hosted_zone on the client 3 times
+ When I call #list_hosted_zone on the client
+ Then the response should contain the created hosted zone ids
+
@@ -0,0 +1,18 @@
+# Copyright 2011-2012 Amazon.com, Inc. or its affiliates. All Rights Reserved.
+#
+# Licensed under the Apache License, Version 2.0 (the "License"). You
+# may not use this file except in compliance with the License. A copy of
+# the License is located at
+#
+# http://aws.amazon.com/apache2.0/
+#
+# or in the "license" file accompanying this file. This file is
+# distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF
+# ANY KIND, either express or implied. See the License for the specific
+# language governing permissions and limitations under the License.
+
+Before("@rds") do
+
+ @rds = AWS::RDS.new
+
+end
@@ -142,7 +142,7 @@ def modify options = {}
# @return [DBSnapshotCollection]
def snapshots
- DBSnapshotCollection.new(:config => config).with_id(id)
+ DBSnapshotCollection.new(:config => config).db_instance(self)
end
# @return [DBSnapshot]

0 comments on commit c34c6e8

Please sign in to comment.