Skip to content

Commit

Permalink
Add TruffleRuby and JRuby nightly tests
Browse files Browse the repository at this point in the history
  • Loading branch information
peterfication committed Jan 9, 2024
1 parent 35e2ea8 commit e2ec768
Show file tree
Hide file tree
Showing 7 changed files with 70 additions and 17 deletions.
1 change: 1 addition & 0 deletions .cspell.dictionary.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
codecov
fcontext
fdescribe
racc
rbprettier
rubocop
srand
18 changes: 18 additions & 0 deletions .github/workflows/jruby-nightly.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
name: JRuby Nightly

on:
schedule:
# Checks daily
- cron: "0 0 * * *"

jobs:
TestsOnNightly:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- run: rm Gemfile.lock
- uses: ruby/setup-ruby@v1
with:
ruby-version: jruby-head
bundler-cache: true
- run: bundle exec rspec
18 changes: 18 additions & 0 deletions .github/workflows/truffleruby-nightly.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
name: TruffleRuby Nightly

on:
schedule:
# Checks daily
- cron: "0 0 * * *"

jobs:
TestsOnNightly:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- run: rm Gemfile.lock
- uses: ruby/setup-ruby@v1
with:
ruby-version: truffleruby-head
bundler-cache: true
- run: bundle exec rspec
23 changes: 14 additions & 9 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,19 @@ source "https://rubygems.org"

gemspec

gem "byebug"
gem "prettier"
gem "pry"
gem "pry-byebug"
gem "rake"
gem "rspec"
gem "rubocop"
gem "rubocop-rake"
gem "rubocop-rspec"
gem "simplecov"
gem "solargraph"

gem "racc" # Needed for JRuby, see https://github.com/jruby/jruby/issues/6581

platforms :mri do
gem "byebug"
gem "prettier"
gem "pry"
gem "pry-byebug"
gem "rubocop"
gem "rubocop-rake"
gem "rubocop-rspec"
gem "simplecov"
gem "solargraph"
end
1 change: 1 addition & 0 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -143,6 +143,7 @@ DEPENDENCIES
prettier
pry
pry-byebug
racc
rake
rspec
rspec-graphql-integration!
Expand Down
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,12 @@
<a href="https://github.com/peterfication/rspec-graphql-integration/actions/workflows/ruby-nightly.yml">
<img alt="CI" src="https://github.com/peterfication/rspec-graphql-integration/actions/workflows/ruby-nightly.yml/badge.svg" \>
</a>
<a href="https://github.com/peterfication/rspec-graphql-integration/actions/workflows/truffleruby-nightly.yml">
<img alt="CI" src="https://github.com/peterfication/rspec-graphql-integration/actions/workflows/truffleruby-nightly.yml/badge.svg" \>
</a>
<a href="https://github.com/peterfication/rspec-graphql-integration/actions/workflows/jruby-nightly.yml">
<img alt="CI" src="https://github.com/peterfication/rspec-graphql-integration/actions/workflows/jruby-nightly.yml/badge.svg" \>
</a>
</p>

<p align="center">
Expand Down
20 changes: 12 additions & 8 deletions spec/spec_helper.rb
Original file line number Diff line number Diff line change
@@ -1,12 +1,16 @@
require "simplecov"
require "byebug"
require "pry"
require "pry-byebug"
begin
require "simplecov"
require "byebug"
require "pry"
require "pry-byebug"

SimpleCov.start do
enable_coverage :branch
primary_coverage :branch
minimum_coverage 100
SimpleCov.start do
enable_coverage :branch
primary_coverage :branch
minimum_coverage 100
end
rescue LoadError
# In TruffleRuby and JRuby, those gems are not installed.
end

require_relative "support/graphql_integration"
Expand Down

0 comments on commit e2ec768

Please sign in to comment.