Skip to content

Commit

Permalink
upgrade to ruby 3
Browse files Browse the repository at this point in the history
  • Loading branch information
sled committed Nov 29, 2023
1 parent c7be016 commit 40554f7
Show file tree
Hide file tree
Showing 9 changed files with 50 additions and 44 deletions.
26 changes: 26 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: Test
on: [push, pull_request]
jobs:
test:
strategy:
fail-fast: false
matrix:
gemfile:
- Gemfile
- gemfiles/rails7.1.gemfile
ruby:
- '3.2'
- '3.1'
exclude:
- gemfile: Gemfile
ruby: '3.2'
runs-on: ubuntu-latest
env: # $BUNDLE_GEMFILE must be set at the job level, so it is set for all steps
BUNDLE_GEMFILE: ${{ matrix.gemfile }}
steps:
- uses: actions/checkout@v3
- uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby }}
bundler-cache: true # runs bundle install and caches installed gems automatically
- run: bundle exec rake
20 changes: 0 additions & 20 deletions .travis.yml

This file was deleted.

2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

Unofficial ruby adapter for MobileTechnics HTTP Bulk SMS API. Tries to mimick
mail API, so users can switch e.g. ActionMailer with this SMS provider. Requires
Ruby 1.9.
Ruby 3+.

## Installation

Expand Down
8 changes: 0 additions & 8 deletions gemfiles/rails4.2.gemfile

This file was deleted.

8 changes: 0 additions & 8 deletions gemfiles/rails5.0.gemfile

This file was deleted.

8 changes: 8 additions & 0 deletions gemfiles/rails6.1.gemfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
source 'http://rubygems.org'

gem 'actionmailer', '~> 6.1'
gem 'activejob', '~> 6.1'

gem 'phony', '~> 2'

gemspec path: '../'
8 changes: 8 additions & 0 deletions gemfiles/rails7.1.gemfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
source 'http://rubygems.org'

gem 'actionmailer', '~> 7.1'
gem 'activejob', '~> 7.1'

gem 'phony', '~> 2'

gemspec path: '../'
12 changes: 6 additions & 6 deletions mote_sms.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ require 'mote_sms/version'
Gem::Specification.new do |gem|
gem.name = 'mote_sms'
gem.version = MoteSMS::VERSION
gem.authors = ['Lukas Westermann', 'Loris Gavillet']
gem.authors = ['Lukas Westermann', 'Loris Gavillet', 'Simon Schmid']
gem.email = ['[email protected]']
gem.summary = 'Deliver SMS using Swisscom / MobileTechnics REST API.'
gem.description = 'Unofficial ruby adapter for Swisscom and MobileTechnics Bulk SMS APIs.
Expand All @@ -22,16 +22,16 @@ Gem::Specification.new do |gem|
gem.test_files = gem.files.grep(%r{^(test|spec|features)/})
gem.require_paths = ['lib']

gem.required_ruby_version = '>= 2.5'
gem.required_ruby_version = '>= 3.1'

gem.add_dependency 'phony', '>= 2'
gem.add_dependency 'activesupport', '>= 5'

gem.add_development_dependency 'rake'
gem.add_development_dependency 'rspec', '~> 3.6'
gem.add_development_dependency 'webmock', '~> 3.14'
gem.add_development_dependency 'actionmailer', '>= 5'
gem.add_development_dependency 'activejob', '>= 5'
gem.add_development_dependency 'twilio-ruby', '>= 4.11.0', '< 5'
gem.add_development_dependency 'obh-client', '~> 0.1'
gem.add_development_dependency 'actionmailer', '>= 6.1'
gem.add_development_dependency 'activejob', '>= 6.1'
gem.add_development_dependency 'twilio-ruby', '~> 6'
gem.add_development_dependency 'obh-client', '~> 0.3'
end
2 changes: 1 addition & 1 deletion spec/mote_sms/message_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@
end

it 'can pass additional attributes to transport' do
expect(transport).to receive(:deliver).with(subject, serviceid: 'myapplication')
expect(transport).to receive(:deliver).with(subject, { serviceid: 'myapplication' })
subject.deliver_now serviceid: 'myapplication'
end

Expand Down

0 comments on commit 40554f7

Please sign in to comment.