Skip to content

A platform for community discussion. Free, open, simple.

DEV: Improve rspec boot time & fix `--bisect` functionality (#34982)

David Taylor33c0041ac550
diff --git a/spec/rails_helper.rb b/spec/rails_helper.rb
index 30ab4dcdc48..ab2deb969dd 100644
--- a/spec/rails_helper.rb
+++ b/spec/rails_helper.rb
@@ -130,13 +130,8 @@ if ENV["LOAD_PLUGINS"] == "1"
Dir[Rails.root.join("plugins/*/spec/system/page_objects/**/*.rb")].each { |f| require f }
end
-# let's not run seed_fu every test
-SeedFu.quiet = true if SeedFu.respond_to? :quiet
-
SiteSetting.automatically_download_gravatars = false
-SeedFu.seed
-
# we need this env var to ensure that we can impersonate in test
# this enable integration_helpers sign_in helper
ENV["DISCOURSE_DEV_ALLOW_ANON_TO_IMPERSONATE"] = "1"
@@ -234,6 +229,9 @@ RSpec.configure do |config|
c.syntax = :expect
end
+ # Default is :fork, but this causes problems if any miniracer context have started
+ config.bisect_runner = :shell
+
config.fail_fast = ENV["RSPEC_FAIL_FAST"] == "1"
config.silence_filter_announcements = ENV["RSPEC_SILENCE_FILTER_ANNOUNCEMENTS"] == "1"
config.extend RedisSnapshotHelper