Skip to content

Commit

Permalink
Bump supported versions to >= 7 and < 9
Browse files Browse the repository at this point in the history
  • Loading branch information
schinery committed Dec 10, 2024
1 parent cc3dbcb commit 9a93c33
Show file tree
Hide file tree
Showing 17 changed files with 999 additions and 33 deletions.
22 changes: 20 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,29 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
ruby: ["3.0", "3.1", "3.2", "3.3"]
ruby:
[
{ version: "3.1", gemfile: activerecord_7 },
{ version: "3.1", gemfile: activerecord_7_1 },
{ version: "3.1", gemfile: activerecord_7_2 },
{ version: "3.2", gemfile: activerecord_7 },
{ version: "3.2", gemfile: activerecord_7_1 },
{ version: "3.2", gemfile: activerecord_7_2 },
{ version: "3.2", gemfile: activerecord_8 },
{ version: "3.2", gemfile: activerecord_main },
{ version: "3.3", gemfile: activerecord_7 },
{ version: "3.3", gemfile: activerecord_7_1 },
{ version: "3.3", gemfile: activerecord_7_2 },
{ version: "3.3", gemfile: activerecord_8 },
{ version: "3.3", gemfile: activerecord_main },
]
env:
BUNDLE_GEMFILE: ${{ github.workspace }}/gemfiles/${{ matrix.ruby.gemfile }}.gemfile
BUNDLE_PATH_RELATIVE_TO_CWD: true
steps:
- uses: actions/checkout@v4
- uses: ruby/setup-ruby@v1
with:
bundler-cache: true
ruby-version: ${{ matrix.ruby }}
ruby-version: ${{ matrix.ruby.version }}
- run: bundle exec rake test
4 changes: 3 additions & 1 deletion .rubocop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,6 @@ require:
- rubocop-rspec

AllCops:
TargetRubyVersion: 3.0
TargetRubyVersion: 3.1
Exclude:
- gemfiles/*
38 changes: 38 additions & 0 deletions Appraisals
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
# frozen_string_literal: true

# Currently doesn't work with Appraisal 2.5.0 and Ruby >= 3.1
# customize_gemfiles do
# {
# heading: <<~HEADING
# # frozen_string_literal: true
#
# `%<gemfile>s` has been generated by Appraisal, do NOT modify it or `%<lockfile>s` directly!
# Make the changes to the "%<appraisal>s" block in `Appraisals` instead.
# HEADING
# }
# end

appraise "activerecord-7" do
gem "activerecord", "~> 7.0.0"
gem "sqlite3", "~> 1.7"
end

appraise "activerecord-7-1" do
gem "activerecord", "~> 7.1.0"
gem "sqlite3", "~> 1.7"
end

appraise "activerecord-7-2" do
gem "activerecord", "~> 7.2.0"
gem "sqlite3", "~> 1.7"
end

appraise "activerecord-8" do
gem "activerecord", "~> 8.0.0"
gem "sqlite3", "~> 2.0"
end

appraise "activerecord-main" do
gem "activerecord", github: "rails/rails", branch: "main"
gem "sqlite3", "~> 2.0"
end
9 changes: 7 additions & 2 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,19 @@ source "https://rubygems.org"

gemspec

gem "activerecord", "~> 8.0"
gem "sqlite3", "~> 2.1"

group :development do
gem "activerecord", "~> 7.1"
gem "appraisal", "~> 2.5"
gem "boxt_rubocop", "2.15.0"
gem "byebug", "~> 11.0"
gem "rake", "~> 13.2"
end

group :test do
gem "rspec", "~> 3.13"
gem "simplecov", "~> 0.22"
gem "sqlite3", "~> 1.7"
gem "timecop", "~> 0.9"
gem "with_model", "~> 2.1"
end
60 changes: 36 additions & 24 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -2,30 +2,38 @@ PATH
remote: .
specs:
logga (5.0.0)
activerecord (>= 6, < 8)
activesupport (>= 6, < 8)
activerecord (>= 7, < 9)
activesupport (>= 7, < 9)

GEM
remote: https://rubygems.org/
specs:
activemodel (7.1.4.2)
activesupport (= 7.1.4.2)
activerecord (7.1.4.2)
activemodel (= 7.1.4.2)
activesupport (= 7.1.4.2)
activemodel (8.0.0)
activesupport (= 8.0.0)
activerecord (8.0.0)
activemodel (= 8.0.0)
activesupport (= 8.0.0)
timeout (>= 0.4.0)
activesupport (7.1.4.2)
activesupport (8.0.0)
base64
benchmark (>= 0.3)
bigdecimal
concurrent-ruby (~> 1.0, >= 1.0.2)
concurrent-ruby (~> 1.0, >= 1.3.1)
connection_pool (>= 2.2.5)
drb
i18n (>= 1.6, < 2)
logger (>= 1.4.2)
minitest (>= 5.1)
mutex_m
tzinfo (~> 2.0)
securerandom (>= 0.3)
tzinfo (~> 2.0, >= 2.0.5)
uri (>= 0.13.1)
appraisal (2.5.0)
bundler
rake
thor (>= 0.14.0)
ast (2.4.2)
base64 (0.2.0)
benchmark (0.4.0)
bigdecimal (3.1.8)
boxt_rubocop (2.15.0)
rubocop (= 1.69.0)
Expand All @@ -39,16 +47,16 @@ GEM
concurrent-ruby (1.3.4)
connection_pool (2.4.1)
diff-lcs (1.5.1)
docile (1.4.0)
docile (1.4.1)
drb (2.2.1)
faker (3.5.1)
i18n (>= 1.8.11, < 2)
i18n (1.14.6)
concurrent-ruby (~> 1.0)
json (2.9.0)
language_server-protocol (3.17.0.3)
logger (1.6.2)
minitest (5.25.4)
mutex_m (0.3.0)
parallel (1.26.3)
parser (3.3.6.0)
ast (~> 2.4.1)
Expand All @@ -62,15 +70,15 @@ GEM
rspec-core (~> 3.13.0)
rspec-expectations (~> 3.13.0)
rspec-mocks (~> 3.13.0)
rspec-core (3.13.0)
rspec-core (3.13.2)
rspec-support (~> 3.13.0)
rspec-expectations (3.13.1)
rspec-expectations (3.13.3)
diff-lcs (>= 1.2.0, < 2.0)
rspec-support (~> 3.13.0)
rspec-mocks (3.13.1)
rspec-mocks (3.13.2)
diff-lcs (>= 1.2.0, < 2.0)
rspec-support (~> 3.13.0)
rspec-support (3.13.1)
rspec-support (3.13.2)
rubocop (1.69.0)
json (~> 2.3)
language_server-protocol (>= 3.17.0)
Expand Down Expand Up @@ -101,22 +109,25 @@ GEM
rubocop-rspec (3.2.0)
rubocop (~> 1.61)
ruby-progressbar (1.13.0)
securerandom (0.4.0)
simplecov (0.22.0)
docile (~> 1.1)
simplecov-html (~> 0.11)
simplecov_json_formatter (~> 0.1)
simplecov-html (0.12.3)
simplecov-html (0.13.1)
simplecov_json_formatter (0.1.4)
sqlite3 (1.7.3-arm64-darwin)
sqlite3 (1.7.3-x86_64-darwin)
sqlite3 (1.7.3-x86_64-linux)
sqlite3 (2.4.1-arm64-darwin)
sqlite3 (2.4.1-x86_64-darwin)
sqlite3 (2.4.1-x86_64-linux-gnu)
thor (1.3.2)
timecop (0.9.10)
timeout (0.4.1)
timeout (0.4.2)
tzinfo (2.0.6)
concurrent-ruby (~> 1.0)
unicode-display_width (3.1.2)
unicode-emoji (~> 4.0, >= 4.0.4)
unicode-emoji (4.0.4)
uri (1.0.2)
with_model (2.1.7)
activerecord (>= 6.0)

Expand All @@ -132,14 +143,15 @@ PLATFORMS
x86_64-linux

DEPENDENCIES
activerecord (~> 7.1)
activerecord (~> 8.0)
appraisal (~> 2.5)
boxt_rubocop (= 2.15.0)
byebug (~> 11.0)
logga!
rake (~> 13.2)
rspec (~> 3.13)
simplecov (~> 0.22)
sqlite3 (~> 1.7)
sqlite3 (~> 2.1)
timecop (~> 0.9)
with_model (~> 2.1)

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

## Development

After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake test` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
After checking out the repo, run `bin/setup` to install dependencies. Then, run `bundle exec appraisal rake test` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.

To install this gem onto your local machine, run `bundle exec rake install`.

Expand Down
22 changes: 22 additions & 0 deletions gemfiles/activerecord_7.gemfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# This file was generated by Appraisal

source "https://rubygems.org"

gem "activerecord", "~> 7.0.0"
gem "sqlite3", "~> 1.7"

group :development do
gem "appraisal", "~> 2.5"
gem "boxt_rubocop", "2.15.0"
gem "byebug", "~> 11.0"
gem "rake", "~> 13.2"
end

group :test do
gem "rspec", "~> 3.13"
gem "simplecov", "~> 0.22"
gem "timecop", "~> 0.9"
gem "with_model", "~> 2.1"
end

gemspec path: "../"
Loading

0 comments on commit 9a93c33

Please sign in to comment.