Skip to content

Commit

Permalink
Skip when JSON.generate is called during tests
Browse files Browse the repository at this point in the history
fix #97
  • Loading branch information
ono-max authored and ko1 committed Jun 17, 2021
1 parent 4bc6d86 commit 9e8fdce
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions lib/debug/session.rb
Original file line number Diff line number Diff line change
Expand Up @@ -473,6 +473,8 @@ def wait_command
@tracer ||= TracePoint.new(){|tp|
next if File.dirname(tp.path) == dir
next if tp.path == '<internal:trace_point>'
# Skip when `JSON.generate` is called during tests
next if tp.binding.eval('self').to_s == 'JSON' and ENV['RUBY_DEBUG_TEST_MODE']
# next if tp.event != :line
@ui.puts pretty_tp(tp)
}
Expand Down

0 comments on commit 9e8fdce

Please sign in to comment.