Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Don't stop byebug with linetrace enabled #264

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
3 changes: 3 additions & 0 deletions ext/byebug/byebug.c
Original file line number Diff line number Diff line change
Expand Up @@ -676,6 +676,9 @@ Stoppable(VALUE self)
if (post_mortem == Qtrue)
return Qfalse;

if (RTEST(tracing))
return Qfalse;

context = Current_context(self);
if (!NIL_P(context))
{
Expand Down
9 changes: 9 additions & 0 deletions test/commands/continue_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -68,5 +68,14 @@ def test_shows_error_if_specified_line_is_not_valid

check_error_includes 'Line 100 is not a valid stopping point in file'
end

def test_tracing_after_set_linetrace_and_continue
with_setting :linetrace, false do
enter 'set linetrace', 'cont'
debug_code(program)

check_output_includes "Tracing: #{example_path}:14 c = b + 5"
end
end
end
end