Improve test suite and CI run performance (#1796)
* Simplify test I came across this test because it was failing JRuby CI runs. I should emphasize, though, that this test was only failing due do an upstream bug in Nokogiri v1.12.5. When I was reviewing the test, to understand why it was failing at all, I noticed that the assertion was rather obfuscated. Specifically, we were post-processing the entire `response.body` and using that as an expectation. * Use an older version of Nokogiri in our test env This is a temporary fix. See the commit diff for more information. * Split JRuby CI runs from MRI CI runs We can improve the performance of our MRI test runs by not installing Java as part of their run. (Java is only required for JRuby.) * Use latest Ruby patch versions during CI runs * Simplify GitHub Action workflow steps Judging by the output in the GitHub Actions workflow UI, the `echo` steps were not providing much value to us. We can get rid of them to slightly increase run performance. I've also named the other steps to make it easier to skim the Actions workflow output. * Remove `twitter_cldr` development dependency This is no longer being used. * Change GitHub Actions workflow Ruby matrix We can drop Ruby 2.4 from our test run matrix. It is beyond EOL. Let's add 2.7 instead.
This commit is contained in:
@@ -1,9 +1,26 @@
|
||||
source 'https://rubygems.org'
|
||||
|
||||
if RUBY_PLATFORM == 'java'
|
||||
gem 'warbler'
|
||||
end
|
||||
gem 'warbler', platforms: :jruby
|
||||
|
||||
# FIXME:
|
||||
#
|
||||
# There's an issue in 1.12.5 that causes XHTML elements to be generated badly,
|
||||
# causing Gollum's test suite to fail.[1] The issue has been fixed upstream,
|
||||
# but we're still waiting for a new Nokogiri point release.
|
||||
#
|
||||
# However, 1.12.5 is a security patch, so we don't want end users to use an
|
||||
# older version of Nokogiri. But this is safe to do in our CI environment.
|
||||
#
|
||||
# Once there's a new Nokogiri release, we can remove this dependency and JRuby
|
||||
# CI should pass normally again.
|
||||
#
|
||||
# Note that Nokogiri 1.11+ does not support Ruby v2.4.x anymore. So to make our
|
||||
# current CI workflows pass, we should only try to install this version of
|
||||
# Nokogiri for newer Ruby versions.
|
||||
#
|
||||
# [1]: https://github.com/gollum/gollum/issues/1779
|
||||
gem 'nokogiri', '1.12.4' unless RUBY_VERSION.include? '2.4'
|
||||
|
||||
gemspec
|
||||
|
||||
gem 'rake', '~> 13.0'
|
||||
gem 'rake', '~> 13.0'
|
||||
|
||||
Reference in New Issue
Block a user