Skip to content
This repository was archived by the owner on Nov 30, 2024. It is now read-only.

Commit 4381f7d

Browse files
committed
Generalize the gem backtrace exclusion.
Previous regex matcher let gems slip through if a custom path was provided to bundler (e.g. `bundle install --path ../bundle`). Remove any explicit path dependencies on potential ruby version based directory names.
1 parent 2c4e16a commit 4381f7d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/rspec/support/spec/stderr_splitter.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ def ==(other)
2525
# To work around JRuby error:
2626
# TypeError: $stderr must have write method, RSpec::StdErrSplitter given
2727
def write(line)
28-
if line !~ /^\S+gems\/ruby\-\S+:\d+: warning:/
28+
if line !~ %r{^\S+/gems/\S+:\d+: warning:} # http://rubular.com/r/kqeUIZOfPG
2929
@orig_stderr.write(line)
3030
@output_tracker.write(line)
3131
end

0 commit comments

Comments
 (0)