Skip to content

Commit bafcc0d

Browse files
author
Twill
committed
build(deps): upgrade dependencies for modern environment compatibility
- Add Ruby 4.0 support (released Dec 2025), bump minimum to Ruby 3.2 - Update Rails 8.1 from beta to stable release - Drop Rails 7.0 (EOL) and JRuby 9.4 (targets Ruby 3.1) from CI - Bump CI default Ruby from 3.4 to 4.0 across all workflows - Update default BUNDLE_GEMFILE to Rails 8.1 - Bump upload-artifact action from v4 to v6 - Update Dockerfile base image to Ruby 4.0 - Update README requirements to match gemspec
1 parent 62419f7 commit bafcc0d

8 files changed

Lines changed: 20 additions & 43 deletions

File tree

.github/actions/upload-screenshots/action.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,14 +8,14 @@ inputs:
88
runs:
99
using: 'composite'
1010
steps:
11-
- uses: actions/upload-artifact@v4
11+
- uses: actions/upload-artifact@v6
1212
with:
1313
name: ${{ inputs.name }}-diffs
1414
retention-days: 1
1515
path: |
1616
test/fixtures/app/doc/screenshots/
1717
18-
- uses: actions/upload-artifact@v4
18+
- uses: actions/upload-artifact@v6
1919
with:
2020
name: ${{ inputs.name }}-capybara-fails
2121
retention-days: 1

.github/workflows/lint.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ jobs:
2525
- name: Set up Ruby
2626
uses: ruby/setup-ruby@v1
2727
with:
28-
ruby-version: '3.3'
28+
ruby-version: '4.0'
2929
bundler-cache: true
3030

3131
- name: Run Standard Ruby linter

.github/workflows/test.yml

Lines changed: 9 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ on:
1515
workflow_dispatch:
1616

1717
env:
18-
BUNDLE_GEMFILE: gemfiles/rails80_gems.rb
18+
BUNDLE_GEMFILE: gemfiles/rails81_gems.rb
1919
DEBIAN_FRONTEND: noninteractive
2020
FERRUM_PROCESS_TIMEOUT: 40
2121
JAVA_OPTS: -Xmn2g -Xms6g -Xmx6g -XX:MetaspaceSize=256m -XX:MaxMetaspaceSize=512m -Xss1m
@@ -42,7 +42,7 @@ jobs:
4242

4343
- uses: ./.github/actions/setup-ruby-and-dependencies
4444
with:
45-
ruby-version: 3.4
45+
ruby-version: '4.0'
4646

4747
- run: bin/rake test
4848
env:
@@ -59,7 +59,7 @@ jobs:
5959

6060
- uses: ./.github/actions/setup-ruby-and-dependencies
6161
with:
62-
ruby-version: 3.4
62+
ruby-version: '4.0'
6363
cache-apt-packages: true
6464

6565
- run: bin/rake test
@@ -93,37 +93,24 @@ jobs:
9393
continue-on-error: ${{ matrix.experimental }}
9494
strategy:
9595
matrix:
96-
ruby-version: [ 3.4, 3.3, 3.2, jruby-9.4, jruby-10.0 ]
96+
ruby-version: [ '4.0', 3.4, 3.3, 3.2, jruby-10.0 ]
9797
gemfile:
9898
- rails71_gems.rb
9999
- rails72_gems.rb
100100
- rails80_gems.rb
101101
- rails81_gems.rb
102102
experimental: [ false ]
103103
exclude:
104-
# We already tested last version
105-
- ruby-version: 3.4
106-
gemfile: rails80_gems.rb
107-
experimental: false
108-
# JRuby 9.x is Ruby 3.1 compatible, and Rails 8 requires Ruby 3.2.
109-
- ruby-version: jruby-9.4
110-
gemfile: rails80_gems.rb
111-
experimental: false
112-
- ruby-version: jruby-9.4
104+
# We already tested last version in the functional-test job
105+
- ruby-version: '4.0'
113106
gemfile: rails81_gems.rb
114107
experimental: false
115108
include:
116-
- ruby-version: 3.5.0-preview1
117-
gemfile: rails81_gems.rb
118-
experimental: true
119-
- ruby-version: 3.5.0-preview1
120-
gemfile: edge_gems.rb
121-
experimental: true
122-
- ruby-version: 3.4
109+
- ruby-version: '4.0'
123110
gemfile: edge_gems.rb
124111
experimental: true
125112
- ruby-version: jruby-head
126-
gemfile: rails80_gems.rb
113+
gemfile: rails81_gems.rb
127114
experimental: true
128115

129116
env:
@@ -168,7 +155,7 @@ jobs:
168155

169156
- uses: ./.github/actions/setup-ruby-and-dependencies
170157
with:
171-
ruby-version: 3.4
158+
ruby-version: '4.0'
172159
cache-apt-packages: ${{ matrix.screenshot-driver == 'vips' }}
173160

174161
- name: Cache Selenium

Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
# $ docker build . -t csd
44
# $ docker run -v $(pwd):/app -ti csd rake test
55

6-
FROM jetthoughts/cimg-ruby:3.4-chrome
6+
FROM jetthoughts/cimg-ruby:4.0-chrome
77

88
ENV DEBIAN_FRONTEND=noninteractive \
99
BUNDLE_PATH=/bundle

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,8 +45,8 @@ Or install it yourself as:
4545

4646
`capybara-screenshot-diff` supports the currently supported versions of Ruby and Rails:
4747

48-
* Ruby 3.0+ (https://www.ruby-lang.org/en/downloads/branches/)
49-
* Rails 6.1+ (https://guides.rubyonrails.org/maintenance_policy.html)
48+
* Ruby 3.2+ (https://www.ruby-lang.org/en/downloads/branches/)
49+
* Rails 7.1+ (https://guides.rubyonrails.org/maintenance_policy.html)
5050

5151
* [for :vips driver] libvips 8.9 or later, see the [libvips install instructions](https://libvips.github.io/libvips/install.html)
5252

capybara-screenshot-diff.gemspec

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ Gem::Specification.new do |spec|
1212
spec.summary = "Track your GUI changes with diff assertions"
1313
spec.description = "Save screen shots and track changes with graphical diff"
1414
spec.homepage = "https://github.com/donv/capybara-screenshot-diff"
15-
spec.required_ruby_version = ">= 3.1"
15+
spec.required_ruby_version = ">= 3.2"
1616
spec.license = "MIT"
1717
spec.metadata["allowed_push_host"] = "https://rubygems.org/"
1818
spec.files = `git ls-files -z`.split("\x0").reject do |f|
@@ -23,7 +23,7 @@ Gem::Specification.new do |spec|
2323
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
2424
spec.require_paths = ["lib"]
2525

26-
spec.add_development_dependency "actionpack", ">= 7.0", "< 9"
27-
spec.add_development_dependency "activesupport", ">= 7.0", "< 9"
26+
spec.add_development_dependency "actionpack", ">= 7.1", "< 9"
27+
spec.add_development_dependency "activesupport", ">= 7.1", "< 9"
2828
spec.add_runtime_dependency "capybara", ">= 2", "< 4"
2929
end

gemfiles/rails70_gems.rb

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

gemfiles/rails81_gems.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,5 @@
33
gems = "#{File.dirname __dir__}/gems.rb"
44
eval File.read(gems), binding, gems
55

6-
gem "activesupport", "~> 8.1.0.beta1"
7-
gem "actionpack", "~> 8.1.0.beta1"
6+
gem "activesupport", "~> 8.1.0"
7+
gem "actionpack", "~> 8.1.0"

0 commit comments

Comments
 (0)