summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Rodríguez <deivid.rodriguez@riseup.net>2020-01-13 12:47:51 +0100
committerDavid Rodríguez <deivid.rodriguez@riseup.net>2020-01-13 12:55:28 +0100
commit104dbfbb1dd8fa2b32fe117c1ae1e4203e0665fe (patch)
tree6beaf50a525af01f91c8f6eb2418be83c86ffda5
parentcb96a16c9b7ffbb50c9929be7058ab1f4a552ca3 (diff)
downloadbundler-104dbfbb1dd8fa2b32fe117c1ae1e4203e0665fe.tar.gz
Load `CompactIndexClient` upfronttests/fix_autoload_thread_safety_issue
To prevent potential autoloading issues in our parallel tests. I think this could be the cause of https://github.com/rubygems/bundler/runs/386607433.
-rw-r--r--spec/bundler/fetcher/compact_index_spec.rb3
1 files changed, 3 insertions, 0 deletions
diff --git a/spec/bundler/fetcher/compact_index_spec.rb b/spec/bundler/fetcher/compact_index_spec.rb
index c9419d3eb1..b00eadceab 100644
--- a/spec/bundler/fetcher/compact_index_spec.rb
+++ b/spec/bundler/fetcher/compact_index_spec.rb
@@ -1,5 +1,8 @@
# frozen_string_literal: true
+# load CompactIndexClient upfront to prevent thread safety issues during parallel specs
+require "bundler/compact_index_client"
+
RSpec.describe Bundler::Fetcher::CompactIndex do
let(:downloader) { double(:downloader) }
let(:display_uri) { Bundler::URI("http://sampleuri.com") }