Skip to content

Commit

Permalink
Update CI workflow and build and install gems on TruffleRuby and JRuby
Browse files Browse the repository at this point in the history
  • Loading branch information
andrykonchin committed Sep 18, 2024
1 parent 4bd5264 commit 0fef565
Showing 1 changed file with 11 additions and 2 deletions.
13 changes: 11 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@ jobs:
include:
- { os: windows-latest , ruby: mingw }
- { os: windows-latest , ruby: mswin }
- { os: ubuntu-latest , ruby: truffleruby }
- { os: ubuntu-latest , ruby: jruby }
exclude:
- { os: macos-14 , ruby: '2.5' }
- { os: windows-latest , ruby: '3.0' }
Expand Down Expand Up @@ -58,16 +60,23 @@ jobs:
- run: gem install pkg/*.gem

- run: rake test
# Don't run tests on TruffleRuby and JRuby because tests don't pass on them yet
if: >-
matrix.ruby != 'truffleruby' &&
matrix.ruby != 'jruby'
env:
RUBYOPT: --disable=gems

- name: Run test against installed gem
# We can't use Fiddle gem with RubyInstaller because
# RubyInstaller requires Fiddle before rubygems is loaded:
# https://github.com/oneclick/rubyinstaller2/blob/master/lib/ruby_installer/build/dll_directory.rb#L1
#
# Don't run tests on TruffleRuby and JRuby because tests don't pass on them yet
if: >-
matrix.os != 'windows-latest' ||
(matrix.os == 'windows-latest' && matrix.ruby == 'mswin')
(matrix.os != 'windows-latest' ||
(matrix.os == 'windows-latest' && matrix.ruby == 'mswin')) &&
(matrix.ruby != 'truffleruby' && matrix.ruby != 'jruby')
run: |
ruby -run -e cp -- -pr test/ tmp/
cd tmp
Expand Down

0 comments on commit 0fef565

Please sign in to comment.