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

Speed up jruby CI test suite #981

Merged
merged 3 commits into from Aug 8, 2020
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
9 changes: 7 additions & 2 deletions .travis.yml
Expand Up @@ -28,8 +28,10 @@ addons:

before_install:
- service haveged start
# Pin bundler version due to https://github.com/rubygems/rubygems/issues/2055
- gem install bundler -v 1.16.0
# Ruby 2.7 adds default bundler with 2.0+ version
# This script removes the default bundler so we can install the version we want
- ./cleanup_bundler
- gem install bundler -v '1.17'

matrix:
include:
Expand All @@ -41,6 +43,9 @@ matrix:
env: RUBYOPT="--enable-frozen-string-literal --debug=frozen-string-literal"
- rvm: ruby-head
env: RAILS_VERSION=0
exclude:
- rvm: 2.7
env: RAILS_VERSION=4

allow_failures:
- rvm: ruby-head
16 changes: 8 additions & 8 deletions Gemfile
Expand Up @@ -3,28 +3,28 @@ source "https://rubygems.org/"
gemspec

if ENV["RAILS_VERSION"] && (ENV["RAILS_VERSION"].to_i == 4)
gem "rails", "< 5"
gem "rspec-rails", "> 3"
gem "rails", "~> 4.2"
gem "rspec-rails", "~> 4.0"
elsif ENV["RAILS_VERSION"] && (ENV["RAILS_VERSION"].to_i == 0)
# no-op. No Rails.
else
gem "rails", "< 6"
gem "rspec-rails", "> 3"
gem "rails", "~> 5.2"
gem "rspec-rails", "~> 4.0"
end

gem "sidekiq"

gem "rack"
gem "rack-timeout"

gem "sidekiq"

gem "pry"
gem "benchmark-ips"
gem "benchmark-ipsa"
gem "ruby-prof", platform: :mri
gem "rake", "> 12"
gem "rubocop", "~> 0.41.1" # Last version that supported 1.9, upgrade to 0.50 after we drop 1.9
gem "rspec", "> 3"
gem "capybara" # rspec system tests
gem "rspec", "~> 3.9.0"
gem "capybara", "~> 3.15.0" # rspec system tests
gem "puma" # rspec system tests

gem "timecop"
Expand Down
10 changes: 10 additions & 0 deletions cleanup_bundler
@@ -0,0 +1,10 @@
#!/usr/bin/env ruby

gempaths = `gem env gempath`.split(":")

gempaths.each do |gempath|
# lookup bundler-*.gemspec files and delete them
# this is the only way to completely cleanup default bundler
# Note: the bundler gemspecs' paths are different for CRuby and JRuby
Dir.glob(gempath.strip + "/specifications/**/bundler-*.gemspec").each { |p| File.delete(p) }
end