From 4229164197a95bdc13b51386a2341a34f466f8a2 Mon Sep 17 00:00:00 2001 From: benjamin wil Date: Wed, 29 Dec 2021 13:17:39 -0800 Subject: [PATCH] Use an older version of Nokogiri in our test env This is a temporary fix. See the commit diff for more information. --- Gemfile | 25 +++++++++++++++++++++---- 1 file changed, 21 insertions(+), 4 deletions(-) diff --git a/Gemfile b/Gemfile index 1d210903..c79d5637 100644 --- a/Gemfile +++ b/Gemfile @@ -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' \ No newline at end of file +gem 'rake', '~> 13.0'