Skip to content

Commit 9ac3187

Browse files
authored
Merge pull request #2528 from ViewComponent/ruby-4-ci
update CI and local dev for ruby 4
2 parents 1722b70 + 8afdd98 commit 9ac3187

File tree

11 files changed

+230
-225
lines changed

11 files changed

+230
-225
lines changed

.github/workflows/ci.yml

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -14,18 +14,18 @@ jobs:
1414
benchmark:
1515
runs-on: ubuntu-latest
1616
env:
17-
BUNDLE_GEMFILE: gemfiles/rails_8.0.gemfile
17+
BUNDLE_GEMFILE: gemfiles/rails_8.1.gemfile
1818
steps:
1919
- uses: actions/checkout@v4.1.1
2020
- name: Setup Ruby
2121
uses: ruby/setup-ruby@v1
2222
with:
23-
ruby-version: 3.4
23+
ruby-version: 4.0
2424
bundler-cache: true
2525
- name: Run benchmarks
2626
run: |
27-
bundle exec appraisal rails-8.0 rake partial_benchmark
28-
bundle exec appraisal rails-8.0 rake translatable_benchmark
27+
bundle exec appraisal rails-8.1 rake partial_benchmark
28+
bundle exec appraisal rails-8.1 rake translatable_benchmark
2929
test:
3030
name: test (Rails ${{ matrix.rails_version }}, Ruby ${{ matrix.ruby_version }})
3131
runs-on: ubuntu-latest
@@ -40,7 +40,7 @@ jobs:
4040
rails_version: "7.2"
4141
- ruby_version: "3.4"
4242
rails_version: "8.0"
43-
- ruby_version: "3.4"
43+
- ruby_version: "4.0"
4444
rails_version: "8.1"
4545
- ruby_version: "head"
4646
rails_version: "main"
@@ -83,7 +83,7 @@ jobs:
8383
- name: Setup Ruby
8484
uses: ruby/setup-ruby@v1
8585
with:
86-
ruby-version: 3.4
86+
ruby-version: 4.0
8787
bundler-cache: true
8888
working-directory: 'view_component'
8989
- uses: actions/setup-node@v4
@@ -99,7 +99,7 @@ jobs:
9999
bundle --quiet && bundle exec rake
100100
env:
101101
VIEW_COMPONENT_PATH: ../view_component
102-
RAILS_VERSION: '8.0.2'
102+
RAILS_VERSION: '8.1.0'
103103
PARALLEL_WORKERS: '1'
104104
coverage:
105105
needs: test
@@ -109,7 +109,7 @@ jobs:
109109
- name: Setup Ruby
110110
uses: ruby/setup-ruby@v1
111111
with:
112-
ruby-version: 3.4
112+
ruby-version: 4.0
113113
bundler-cache: true
114114
- name: Download coverage results
115115
uses: actions/download-artifact@v4.3.0

.github/workflows/lint.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ jobs:
7373
- name: Setup Ruby
7474
uses: ruby/setup-ruby@v1
7575
with:
76-
ruby-version: 3.4
76+
ruby-version: 4.0
7777
- uses: actions/cache@v4
7878
with:
7979
path: vendor/bundle

.tool-versions

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
ruby 3.4.7
1+
ruby 4.0.0

Gemfile

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,11 @@
33
source "https://rubygems.org"
44
gemspec
55

6-
rails_version = (ENV["RAILS_VERSION"] || "~> 8").to_s
6+
rails_version = (ENV["RAILS_VERSION"] || "~> 8.1").to_s
77

88
gem "rails", (rails_version == "main") ? {git: "https://github.com/rails/rails", ref: "main"} : rails_version
99

10-
ruby_version = (ENV["RUBY_VERSION"] || "~> 3.4").to_s
10+
ruby_version = (ENV["RUBY_VERSION"] || "~> 4.0").to_s
1111
ruby ruby_version
1212

1313
group :development, :test do
@@ -26,6 +26,7 @@ group :development, :test do
2626
gem "m", "~> 1"
2727
gem "method_source", "~> 1"
2828
gem "minitest", "~> 6"
29+
gem "nokogiri", "1.19.0"
2930
gem "propshaft", "~> 1"
3031
gem "puma", ">= 6"
3132
gem "rake", "~> 13"

0 commit comments

Comments
 (0)