Skip to content

Commit

Permalink
Add Ruby 3.3, Drop Ruby < 3.0 and Rails < 6.1 (#41)
Browse files Browse the repository at this point in the history
* drop obsoleted rails and ruby versions

- drop rails < 6.1
- drop ruby < 3.0

* add ruby 3.3 in CI

* fix deprecation warning

```
DEPRECATION WARNING: Support for
`config.active_support.cache_format_version = 6.1` has been deprecated
and will be removed in Rails 7.2.
```

* fix deprecation warning

`fixture_path=` has deprecated

ref: https://edgeguides.rubyonrails.org/7_1_release_notes.html#active-record-deprecations

* fix load_defaults version number for RAILS_VERSION=master
  • Loading branch information
kzkn authored Dec 28, 2023
1 parent 86f5b5a commit 57da033
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 17 deletions.
18 changes: 2 additions & 16 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,22 +11,8 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
rails_version: [5.1.0, 5.2.0, 6.0.0, 6.1.0, 7.0.0, 7.1.0, master]
ruby_version: ['3.2', '3.1', '3.0', '2.7', '2.6']
exclude:
- { ruby_version: '2.6', rails_version: 7.0.0 }
- { ruby_version: '2.6', rails_version: 7.1.0 }
- { ruby_version: '2.6', rails_version: master }
- { ruby_version: '3.0', rails_version: 5.1.0 }
- { ruby_version: '3.0', rails_version: 5.2.0 }
- { ruby_version: '3.1', rails_version: 5.1.0 }
- { ruby_version: '3.1', rails_version: 5.2.0 }
- { ruby_version: '3.1', rails_version: 6.0.0 }
- { ruby_version: '3.1', rails_version: 6.1.0 }
- { ruby_version: '3.2', rails_version: 5.1.0 }
- { ruby_version: '3.2', rails_version: 5.2.0 }
- { ruby_version: '3.2', rails_version: 6.0.0 }
- { ruby_version: '3.2', rails_version: 6.1.0 }
rails_version: [6.1.0, 7.0.0, 7.1.0, master]
ruby_version: ['3.3', '3.2', '3.1', '3.0']

steps:
- uses: actions/checkout@v3
Expand Down
1 change: 1 addition & 0 deletions spec/dummy/config/application.rb
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@

module Dummy
class Application < Rails::Application
config.load_defaults Rails.version.to_f
config.secret_token = "secret token"
config.active_support.deprecation = :log
config.eager_load = false
Expand Down
7 changes: 6 additions & 1 deletion spec/rails_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,12 @@
end
RSpec.configure do |config|
# Remove this line if you're not using ActiveRecord or ActiveRecord fixtures
config.fixture_path = File.expand_path('fixtures', __dir__)
fixture_path = File.expand_path('fixtures', __dir__)
if config.respond_to?(:fixture_paths=) # NOTE: check for Rails 6.1
config.fixture_paths = [fixture_path]
else
config.fixture_path = fixture_path
end

# If you're not using ActiveRecord, or you'd prefer not to run each of your
# examples within a transaction, remove the following line or assign false
Expand Down

0 comments on commit 57da033

Please sign in to comment.