Skip to content

Commit

Permalink
Add Truffleruby support (#1612)
Browse files Browse the repository at this point in the history
* Add Truffleruby support

Add Truffleruby support to CI

* Update CHANGELOG.md

* Update CHANGELOG.md

* Update README.md

* Fix review comment
  • Loading branch information
gogainda committed Feb 8, 2022
1 parent 04f42c3 commit 3ebc762
Show file tree
Hide file tree
Showing 6 changed files with 34 additions and 1 deletion.
2 changes: 2 additions & 0 deletions .github/workflows/cucumber-ruby.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ jobs:
include:
- os: ubuntu-latest
ruby: jruby-9.3
- os: ubuntu-latest
ruby: truffleruby-head

runs-on: ${{ matrix.os }}
steps:
Expand Down
25 changes: 25 additions & 0 deletions .github/workflows/rubocop.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: Lint

on:
push:
branches:
- main
pull_request:
branches:
- main

jobs:
rubocop:
runs-on: ubuntu-latest
strategy:
matrix:
ruby-version: ['3.1']
steps:
- uses: actions/checkout@v2
- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby-version }}
bundler-cache: true # runs 'bundle install' and caches installed gems automatically
- name: Run tests
run: bundle exec rake rubocop
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,10 @@ Please visit [cucumber/CONTRIBUTING.md](https://github.com/cucumber/cucumber/blo

### Added

- Add support for TruffleRuby
([PR#1612](https://github.com/cucumber/cucumber-ruby/pull/1612)
[gogainda](https://github.com/gogainda))

### Fixed

### Changed
Expand Down
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ Later in this document, bundler is considered being used so all commands are usi
- Ruby 3.0
- Ruby 2.7
- Ruby 2.6
- TruffleRuby 22.0.0+
- JRuby (with [some limitations](https://github.com/cucumber/cucumber-ruby/blob/main/docs/jruby-limitations.md))
- 9.3 >= 9.3.1 (there is a known issue with JRuby 9.3.0. More info can
be found in the [PR#1571](https://github.com/cucumber/cucumber-ruby/pull/1571).)
Expand Down
2 changes: 1 addition & 1 deletion Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ RuboCop::RakeTask.new
require 'cucumber/rake/task'
Cucumber::Rake::Task.new

default_tasks = %i[spec cucumber cck rubocop]
default_tasks = %i[spec cucumber cck]

default_tasks << :examples if ENV['CI']

Expand Down
1 change: 1 addition & 0 deletions lib/cucumber/formatter/backtrace_filter.rb
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ module Formatter
@backtrace_filters << RbConfig::CONFIG['rubylibdir'] if RbConfig::CONFIG['rubylibdir']

@backtrace_filters << 'org/jruby/' if ::Cucumber::JRUBY
@backtrace_filters << '<internal:' if RUBY_ENGINE == 'truffleruby'

BACKTRACE_FILTER_PATTERNS = Regexp.new(@backtrace_filters.join('|'))

Expand Down

0 comments on commit 3ebc762

Please sign in to comment.