-
Notifications
You must be signed in to change notification settings - Fork 149
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Add testing infrastructure This adds testing infrastructure to test against multiple versions of Rails, including Rails `main` branch. * Test shared behavior of installer commands This adds test coverage for the shared behavior of the installer commands. The commands are tested against a freshly generated Rails app using the version of Rails that is currently loaded. Thus the installers can be tested with different versions of Rails in CI. * Test specific behavior of javascript:install:bun This adds test coverage for specific behavior of the `javascript:install:bun` command. * Test specific behavior of javascript:install:esbuild This adds test coverage for specific behavior of the `javascript:install:esbuild` command. * Test specific behavior of javascript:install:rollup This adds test coverage for specific behavior of the `javascript:install:rollup` command. * Test specific behavior of javascript:install:webpack This adds test coverage for specific behavior of the `javascript:install:webpack` command.
- Loading branch information
1 parent
38fbbae
commit 7054254
Showing
17 changed files
with
1,066 additions
and
116 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
name: CI | ||
on: [push, pull_request] | ||
jobs: | ||
tests: | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
ruby-version: | ||
- "3.1" | ||
- "3.2" | ||
- "3.3" | ||
gemfile: | ||
- gemfiles/rails_7_0.gemfile | ||
- gemfiles/rails_7_1.gemfile | ||
- gemfiles/rails_main.gemfile | ||
continue-on-error: [ false ] | ||
|
||
name: ${{ format('Tests (Ruby {0}, {1})', matrix.ruby-version, matrix.gemfile) }} | ||
runs-on: ubuntu-latest | ||
continue-on-error: ${{ matrix.continue-on-error }} | ||
|
||
env: | ||
BUNDLE_GEMFILE: ${{ matrix.gemfile }} | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Remove Gemfile lock | ||
run: | | ||
rm -f $BUNDLE_GEMFILE.lock | ||
- name: Install Ruby | ||
uses: ruby/setup-ruby@v1 | ||
with: | ||
ruby-version: ${{ matrix.ruby-version }} | ||
bundler-cache: true | ||
|
||
- name: Run tests | ||
run: | | ||
bundle exec rake |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,6 @@ | ||
/tmp/ | ||
.byebug_history | ||
*.gem | ||
|
||
# Ignore Gemfile.lock files for Rails main branch. | ||
/gemfiles/rails_main*.gemfile.lock |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
appraise "rails_7_0" do | ||
gem "rails", "~> 7.0.0" | ||
gem "propshaft" | ||
end | ||
|
||
appraise "rails_7_1" do | ||
gem "rails", "~> 7.1.0" | ||
gem "propshaft" | ||
end | ||
|
||
appraise "rails_main" do | ||
gem "rails", github: "rails/rails", branch: "main" | ||
gem "propshaft" | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.