From 4f7c5654aeba2192396b88e6affdd202478a46ce Mon Sep 17 00:00:00 2001 From: Shlomi Fish Date: Thu, 27 Sep 2012 19:50:05 +0200 Subject: [PATCH] [perl5db] add a test for o PrintRet=0. --- lib/perl5db.t | 29 +++++++++++++++++++++++++++-- 1 file changed, 27 insertions(+), 2 deletions(-) diff --git a/lib/perl5db.t b/lib/perl5db.t index 0ef2eb1..68d59c7 100644 --- a/lib/perl5db.t +++ b/lib/perl5db.t @@ -28,7 +28,7 @@ BEGIN { } } -plan(98); +plan(99); my $rc_filename = '.perldb'; @@ -2326,7 +2326,7 @@ sub _calc_trace_wrapper ); } -# Test the o PrintRet=1 command +# Test the o PrintRet=1 option { my $wrapper = DebugWrap->new( { @@ -2351,6 +2351,31 @@ sub _calc_trace_wrapper ); } +# Test the o PrintRet=0 option +{ + my $wrapper = DebugWrap->new( + { + cmds => + [ + 'o PrintRet=0', + 'b 29', + 'c', + q/$x = 's';/, + 'b 10', + 'c', + 'r', + 'q', + ], + prog => '../lib/perl5db/t/test-PrintRet-option-1', + } + ); + + $wrapper->contents_unlike( + qr/scalar context/, + "Test o PrintRet=0", + ); +} + END { 1 while unlink ($rc_filename, $out_fn); } -- 2.7.4