Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add workflow to ensure the gem installs fine on truffleruby #74

Merged
merged 1 commit into from
Nov 30, 2023

Conversation

eregon
Copy link
Member

@eregon eregon commented Nov 28, 2023

Follow-up of #71.
As explained there we can't run the full test suite on truffleruby yet.
But we can test that the gem installs fine on TruffleRuby, which is already valuable.

@kou
Copy link
Member

kou commented Nov 29, 2023

How about just changing existing workflow?

diff --git a/.github/workflows/ubuntu.yml b/.github/workflows/ubuntu.yml
index 361a4eb..60557d0 100644
--- a/.github/workflows/ubuntu.yml
+++ b/.github/workflows/ubuntu.yml
@@ -42,5 +42,12 @@ jobs:
       env:
         GH_TOKEN: ${{ github.token }}
     - name: Run test
+      # TODO
+      if: >-
+        matrix.ruby != 'truffleruby-head'
       run: bundle exec rake
       continue-on-error: ${{ startsWith(matrix.ruby, 'jruby') }}
+    - name: Install gem
+      run: |
+        gem install pkg/*.gem
+        ruby -rstringio -e 'puts(StringIO::VERSION)'

@eregon
Copy link
Member Author

eregon commented Nov 29, 2023

OK, I'll do that.

Comment on lines +45 to +47
# Tests don't pass yet on truffleruby
if: >-
matrix.ruby != 'truffleruby-head'
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We could also use continue-on-error like for jruby just below, not sure what is best.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Right. I don't have an opinion for this. You can choose whichever you like.

@eregon
Copy link
Member Author

eregon commented Nov 29, 2023

@kou Done, and CI passing

Copy link
Member

@kou kou left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1

- name: Install gem
run: |
gem install pkg/*.gem
ruby -rstringio -e 'puts StringIO::VERSION'
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just for confirmation: This outputs 3.0.1 (not 3.1.1) on truffleruby-head. It's intentional, right?

https://github.com/ruby/stringio/actions/runs/7032124053/job/19135198739?pr=74#step:9:9

3.0.1

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, because it uses truffleruby's stringio.rb.

@eregon eregon merged commit 8197fc7 into ruby:master Nov 30, 2023
28 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants