Skip to content

Commit

Permalink
Minor Integration test fixes (#2966)
Browse files Browse the repository at this point in the history
  • Loading branch information
alextwoods authored Dec 8, 2023
1 parent 898bf5c commit d12b821
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 13 deletions.
4 changes: 0 additions & 4 deletions gems/aws-sdk-codedeploy/features/client.feature
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,3 @@ Feature: Amazon CodeDeploy
When I attempt to call the "GetApplication" API with:
| applicationName | bogus-app |
Then I expect the response error code to be "ApplicationDoesNotExistException"
And I expect the response error message to include:
"""
No application found for name: bogus-app
"""
11 changes: 4 additions & 7 deletions gems/aws-sdk-s3/features/client/presigned.feature
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,9 @@ Feature: S3 Presigned Operations
Scenario: Presigning a put object request
When I create a presigned url for "put_object" with:
| key | test |
| acl | public-read |
And I send an HTTP put request for the presigned url with body "hello"
Then I make an unauthenticated HTTPS GET request for key "test"
And the response should be "hello"
Then I get the object with the key "test"
And the body #read method should return "hello"

Scenario: Presigned GET with virtual-hosted bucket
Given I have a bucket configured with a virtual hosted CNAME
Expand All @@ -39,17 +38,15 @@ Feature: S3 Presigned Operations
Scenario: Presigning a put object request with x-amz-*
When I create a presigned url for "put_object" with:
| key | test |
| acl | public-read |
| storage_class | REDUCED_REDUNDANCY |
And I send an HTTP put request for the presigned url with body "hello"
Then the object "test" should have a "REDUCED_REDUNDANCY" storage class
Then I make an unauthenticated HTTPS GET request for key "test"
And the response should be "hello"
And I get the object with the key "test"
And the body #read method should return "hello"

Scenario: Presigned PUT with content-type
When I create a presigned url for "put_object" with:
| key | test |
| acl | public-read |
| content_type | text/plain |
When I send an HTTP put request with the content type as "text/plain"
Then the response should have a 200 status code
Expand Down
7 changes: 5 additions & 2 deletions tasks/test.rake
Original file line number Diff line number Diff line change
Expand Up @@ -47,15 +47,18 @@ end

rule /^test:features:.+$/ do |task|
dir = "gems/#{task.name.split(':').last}/features"
tags = "-t 'not @veryslow'"
# Exclude support smoke tests as these require account settings
# the logical or with not results in skipping tests marked with
# @support AND @smoke only.
tags = "-t 'not @veryslow' -t 'not @support or not @smoke'"
sh("bundle exec cucumber --retry 3 #{tags} -r #{dir} #{dir} --publish-quiet")
end

desc 'Executes integration tests.'
task 'test:features' do
failures = []
Dir.glob('gems/*/features').each do |dir|
tags = "-t 'not @veryslow'"
tags = "-t 'not @veryslow' -t 'not @support or not @smoke'"
sh("bundle exec cucumber --retry 3 #{tags} -r #{dir} #{dir} --publish-quiet") do |ok, _|
failures << File.basename(File.dirname(dir)) unless ok
end
Expand Down

0 comments on commit d12b821

Please sign in to comment.