Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
mattwynne committed Jul 2, 2016
1 parent 25d2ca5 commit 89a8cc7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/cucumber/formatter/backtrace_filter.rb
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,9 @@ def exception
return @exception if ::Cucumber.use_full_backtrace

pwd_pattern = /#{::Regexp.escape(::Dir.pwd)}\//m
@exception.backtrace.each { |line| line.gsub!(pwd_pattern, "./") }
backtrace = @exception.backtrace.map { |line| line.gsub(pwd_pattern, "./") }

filtered = (@exception.backtrace || []).reject do |line|
filtered = (backtrace || []).reject do |line|
BACKTRACE_FILTER_PATTERNS.detect { |p| line =~ p }
end

Expand Down

0 comments on commit 89a8cc7

Please sign in to comment.