summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSamuel Giddins <segiddins@segiddins.me>2017-01-15 12:42:19 -0600
committerSamuel Giddins <segiddins@segiddins.me>2017-01-15 12:42:19 -0600
commitb151dcdfe72b23183a916874389d725fe40e1dc5 (patch)
tree51372ed864673cf586b6215b4145eac142988135
parentd7bafcc38ddc605a5bd5636ae3d40dcb51bf1720 (diff)
downloadbundler-b151dcdfe72b23183a916874389d725fe40e1dc5.tar.gz
Fail when > 25 spec examples have failed
-rw-r--r--spec/spec_helper.rb6
1 files changed, 6 insertions, 0 deletions
diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb
index 5574c4ae3b..ff9007bd02 100644
--- a/spec/spec_helper.rb
+++ b/spec/spec_helper.rb
@@ -65,6 +65,12 @@ RSpec.configure do |config|
# Enable flags like --only-failures and --next-failure
config.example_status_persistence_file_path = ".rspec_status"
+ # Since failures cause us to keep a bunch of long strings in memory, stop
+ # once we have a large number of failures (indicative of core pieces of
+ # bundler being broken) so that running the full test suite doesn't take
+ # forever due to memory constraints
+ config.fail_fast ||= 25
+
if ENV["BUNDLER_SUDO_TESTS"] && Spec::Sudo.present?
config.filter_run :sudo => true
else