Skip to content

Commit cfedc73

Browse files
mensfeldmyumura
andauthored
Fix integration tests by updating aws-sdk-sqs and replacing moto (#783)
* Fix integration tests by updating aws-sdk-sqs and replacing moto with LocalStack (#782) * Increase timeout in integration tests to fix flaky failures * Provide an xml parser engine for aws sdk core version 2 * update aws-sdk-sqs * Remove queue cleanup in integration tests as moto/localstack handle it automatically * Replace moto with LocalStack in integration tests * Replace moto with LocalStack in integration tests * Fix LocalStack service configuration in GitHub Actions * remove super old rails and ruby * adjust specs * update changelog --------- Co-authored-by: yumu <mifukumandolin0323@gmail.com>
1 parent 5442f47 commit cfedc73

File tree

10 files changed

+32
-84
lines changed

10 files changed

+32
-84
lines changed

.github/workflows/specs.yml

Lines changed: 12 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -9,14 +9,21 @@ jobs:
99
name: All Specs
1010
strategy:
1111
matrix:
12-
ruby: ['2.4', '2.5', '2.6', '2.7', '3.0', '3.1', '3.2', '3.3']
12+
ruby: ['2.7', '3.0', '3.1', '3.2', '3.3']
1313
gemfile: ['Gemfile', 'gemfiles/aws_sdk_core_2.gemfile']
1414
runs-on: ubuntu-20.04
1515
services:
16-
moto_sqs:
17-
image: quay.io/cjlarose/moto-sqs-server:1.1.0
16+
localstack:
17+
image: localstack/localstack:latest
18+
env:
19+
SERVICES: sqs
1820
ports:
19-
- 5000:5000
21+
- 4566:4566
22+
options: >-
23+
--health-cmd "curl -f http://localhost:4566/_localstack/health"
24+
--health-interval 5s
25+
--health-timeout 10s
26+
--health-retries 5
2027
env:
2128
BUNDLE_GEMFILE: ${{ matrix.gemfile }}
2229
steps:
@@ -34,17 +41,8 @@ jobs:
3441
name: Rails Specs
3542
strategy:
3643
matrix:
37-
rails: ['4.2', '5.2', '6.0', '6.1', '7.0', '7.1']
44+
rails: ['6.1', '7.0', '7.1']
3845
include:
39-
- rails: '4.2'
40-
ruby: '2.2'
41-
gemfile: gemfiles/rails_4_2.gemfile
42-
- rails: '5.2'
43-
ruby: '2.5'
44-
gemfile: gemfiles/rails_5_2.gemfile
45-
- rails: '6.0'
46-
ruby: '2.6'
47-
gemfile: gemfiles/rails_6_0.gemfile
4846
- rails: '6.1'
4947
ruby: '3.0'
5048
gemfile: gemfiles/rails_6_1.gemfile

CHANGELOG.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,18 @@
1+
## [7.0.0] - Unreleased
2+
3+
- Fix integration tests by updating aws-sdk-sqs and replacing moto with LocalStack
4+
- [#782](https://github.com/ruby-shoryuken/shoryuken/pull/782)
5+
- [#783](https://github.com/ruby-shoryuken/shoryuken/pull/783)
6+
7+
- Breaking: Remove support of Ruby versions older than 2.7
8+
- [#783](https://github.com/ruby-shoryuken/shoryuken/pull/783)
9+
10+
- Breaking: Remove support of Rails versions older than 6.1
11+
- [#783](https://github.com/ruby-shoryuken/shoryuken/pull/783)
12+
13+
- Breaking: Require `aws-sdk-sqs` `>=` `1.66`:
14+
- [#783](https://github.com/ruby-shoryuken/shoryuken/pull/783)
15+
116
## [v6.2.1] - 2024-02-09
217

318
- Bugfix: Not able to use extended polling strategy (#759)

Gemfile

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,7 @@ gemspec
66
group :test do
77
gem 'activejob'
88
gem 'aws-sdk-core', '~> 3'
9-
# Pin to 1.65.0 because of below issues:
10-
# - https://github.com/ruby-shoryuken/shoryuken/pull/753#issuecomment-1822720647
11-
# - https://github.com/getmoto/moto/issues/7054
12-
gem 'aws-sdk-sqs', '1.65.0'
9+
gem 'aws-sdk-sqs'
1310
gem 'codeclimate-test-reporter', require: nil
1411
gem 'httparty'
1512
gem 'multi_xml'

gemfiles/aws_sdk_core_2.gemfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,10 @@ source "https://rubygems.org"
44

55
group :test do
66
gem "activejob"
7-
gem "aws-sdk-core", "~> 2"
87
gem "codeclimate-test-reporter", require: nil
98
gem "httparty"
109
gem "multi_xml"
10+
gem "nokogiri"
1111
gem "simplecov"
1212
gem "webrick"
1313
end

gemfiles/rails_4_2.gemfile

Lines changed: 0 additions & 20 deletions
This file was deleted.

gemfiles/rails_5_2.gemfile

Lines changed: 0 additions & 21 deletions
This file was deleted.

gemfiles/rails_6_0.gemfile

Lines changed: 0 additions & 21 deletions
This file was deleted.

lib/shoryuken/version.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
module Shoryuken
2-
VERSION = '6.2.1'.freeze
2+
VERSION = '7.0.0.alpha1'.freeze
33
end

shoryuken.gemspec

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ Gem::Specification.new do |spec|
2121
spec.add_development_dependency 'rake'
2222
spec.add_development_dependency 'rspec'
2323

24-
spec.add_dependency 'aws-sdk-core', '>= 2'
24+
spec.add_dependency 'aws-sdk-sqs', '>= 1.66.0'
2525
spec.add_dependency 'concurrent-ruby'
2626
spec.add_dependency 'thor'
2727
end

spec/integration/launcher_spec.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
let(:sqs_client) do
88
Aws::SQS::Client.new(
99
region: 'us-east-1',
10-
endpoint: 'http://localhost:5000',
10+
endpoint: 'http://localhost:4566',
1111
access_key_id: 'fake',
1212
secret_access_key: 'fake'
1313
)

0 commit comments

Comments
 (0)