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

Use GitHub Actions instead of CircleCI for JRuby matrix #10932

Merged
merged 1 commit into from Aug 30, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
39 changes: 1 addition & 38 deletions .circleci/config.yml
Expand Up @@ -2,11 +2,6 @@
# Please keep /.mergify.yml synced!
version: 2

jruby_env: &jruby_env
# By default we have 2 CPUs and 4GB ram available
# https://circleci.com/docs/2.0/configuration-reference/#resource_class
JRUBY_OPTS: "--debug -J-Xmn1024m -J-Xms2048m -J-Xmx2048m"

common_env: &common_env
# CircleCI container has two cores, but Ruby can see 32 cores. So we
# configure test-queue.
Expand Down Expand Up @@ -161,32 +156,6 @@ jobs:
steps:
*rubocop_steps

# JRuby 9.3
jruby-9.3-spec:
docker:
- image: circleci/jruby:9.3
environment:
<<: *common_env
<<: *jruby_env
steps:
*spec_steps
jruby-9.3-ascii_spec:
docker:
- image: circleci/jruby:9.3
environment:
<<: *common_env
<<: *jruby_env
steps:
*ascii_spec_steps
jruby-9.3-rubocop:
docker:
- image: circleci/jruby:9.3
environment:
<<: *common_env
<<: *jruby_env
steps:
*rubocop_steps

# Job for downloading the Code Climate test reporter
cc-setup:
docker:
Expand Down Expand Up @@ -221,7 +190,7 @@ jobs:
- run:
name: Upload coverage results to Code Climate
command: |
./tmp/cc-test-reporter sum-coverage tmp/codeclimate.*.json --parts 5 --output tmp/codeclimate.total.json
./tmp/cc-test-reporter sum-coverage tmp/codeclimate.*.json --parts 4 --output tmp/codeclimate.total.json
./tmp/cc-test-reporter upload-coverage --input tmp/codeclimate.total.json

# Miscellaneous tasks
Expand Down Expand Up @@ -272,16 +241,10 @@ workflows:
- cc-setup
- ruby-head-ascii_spec
- ruby-head-rubocop
- jruby-9.3-spec:
requires:
- cc-setup
- jruby-9.3-ascii_spec
- jruby-9.3-rubocop

- cc-upload-coverage:
requires:
- ruby-2.6-spec
- ruby-2.7-spec
- ruby-3.0-spec
- ruby-3.1-spec
- jruby-9.3-spec
20 changes: 20 additions & 0 deletions .github/workflows/rubocop.yml
Expand Up @@ -53,6 +53,26 @@ jobs:
- name: internal_investigation
run: bundle exec rake internal_investigation

jruby:
name: JRuby 9.3
runs-on: ubuntu-latest
steps:
- name: checkout
uses: actions/checkout@v3
- name: set up Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: jruby-9.3

- name: install dependencies
run: bundle install --jobs 3 --retry 3
- name: spec
run: bundle exec rake spec
- name: ascii_spec
run: bundle exec rake ascii_spec
- name: internal_investigation
run: bundle exec rake internal_investigation

rspec4:
runs-on: ubuntu-latest
name: RSpec 4
Expand Down
4 changes: 1 addition & 3 deletions spec/spec_helper.rb
Expand Up @@ -58,9 +58,7 @@
config.filter_run_excluding broken_on: :ruby_head
end

if %w[jruby-9.3-ascii_spec jruby-9.3-spec].include? ENV.fetch('CIRCLE_JOB', nil)
config.filter_run_excluding broken_on: :jruby
end
config.filter_run_excluding broken_on: :jruby if ENV.fetch('GITHUB_JOB', nil) == 'jruby'
end

module ::RSpec
Expand Down