From 58c09e0f8574ba18f38bf6f5864b28b60da51009 Mon Sep 17 00:00:00 2001 From: Benoit Daloze Date: Tue, 21 Feb 2023 16:55:40 +0100 Subject: [PATCH] Add TruffleRuby in CI --- .github/workflows/stable.yml | 10 ++++++++-- .github/workflows/unstable.yml | 10 ++++++++-- spec/return_codes_spec.rb | 1 + 3 files changed, 17 insertions(+), 4 deletions(-) diff --git a/.github/workflows/stable.yml b/.github/workflows/stable.yml index 891a4b7f..8834ca8a 100644 --- a/.github/workflows/stable.yml +++ b/.github/workflows/stable.yml @@ -19,6 +19,7 @@ jobs: - '3.2' - '3.3' - jruby-9.4 + - truffleruby steps: - uses: actions/checkout@v4 @@ -28,5 +29,10 @@ jobs: ruby-version: ${{ matrix.ruby-version }} bundler-cache: true - - run: | - bundle exec rake + - name: Run tests + run: bundle exec rake + if: matrix.ruby-version != 'truffleruby' + + - name: Run specs (truffleruby) + run: bundle exec rake spec + if: matrix.ruby-version == 'truffleruby' diff --git a/.github/workflows/unstable.yml b/.github/workflows/unstable.yml index 70d676a0..158df62c 100644 --- a/.github/workflows/unstable.yml +++ b/.github/workflows/unstable.yml @@ -17,6 +17,7 @@ jobs: ruby-version: - ruby-head - jruby-head + - truffleruby-head steps: - uses: actions/checkout@v4 @@ -27,6 +28,11 @@ jobs: bundler-cache: true continue-on-error: ${{ (matrix.ruby-version == 'ruby-head') || (matrix.ruby-version == 'jruby-head') }} - - run: | - bundle exec rake + - name: Run tests + run: bundle exec rake + if: matrix.ruby-version != 'truffleruby-head' continue-on-error: ${{ (matrix.ruby-version == 'ruby-head') || (matrix.ruby-version == 'jruby-head') }} + + - name: Run specs (truffleruby) + run: bundle exec rake spec + if: matrix.ruby-version == 'truffleruby-head' diff --git a/spec/return_codes_spec.rb b/spec/return_codes_spec.rb index 36b2dd31..3f849987 100644 --- a/spec/return_codes_spec.rb +++ b/spec/return_codes_spec.rb @@ -34,6 +34,7 @@ end it "prints a message to STDERR" do + skip "fails on truffleruby" if RUBY_ENGINE == "truffleruby" && command.include?("testunit_bad.rb") expect(@stderr).to match(/stopped.+SimpleCov.+previous.+error/i) end end