diff options
author | Shlomi Fish <shlomif@shlomifish.org> | 2012-09-18 17:24:14 +0300 |
---|---|---|
committer | Ricardo Signes <rjbs@cpan.org> | 2012-11-12 09:18:23 -0500 |
commit | 8b842515d9c6944f4ebda2e213d04f07b503bdd6 (patch) | |
tree | ef81db078669630021d8763269b0c35233b261d9 /lib/perl5db.t | |
parent | 2bceee64ee91178a2f5b5d15f7b36bff19ff06fa (diff) | |
download | perl-8b842515d9c6944f4ebda2e213d04f07b503bdd6.tar.gz |
[perl5db] Test the recallCommand option.
Diffstat (limited to 'lib/perl5db.t')
-rw-r--r-- | lib/perl5db.t | 31 |
1 files changed, 30 insertions, 1 deletions
diff --git a/lib/perl5db.t b/lib/perl5db.t index c3a072ca2b..87256b39b8 100644 --- a/lib/perl5db.t +++ b/lib/perl5db.t @@ -28,7 +28,7 @@ BEGIN { } } -plan(89); +plan(90); my $rc_filename = '.perldb'; @@ -2120,6 +2120,35 @@ sub _calc_trace_wrapper } +# Test the recallCommand option. +{ + my $wrapper = DebugWrap->new( + { + cmds => + [ + 'o recallCommand=%', + 'l 3-5', + 'l 2', + '% -1', + 'q', + ], + prog => '../lib/perl5db/t/disable-breakpoints-1', + } + ); + + $wrapper->contents_like(qr# + (^3:\s+my\ \$dummy\ =\ 0;\n + 4\s*\n + 5:\s+\$x\ =\ "FirstVal";)\n + .*? + ^2==\>\s+my\ \$x\ =\ "One";\n + .*? + ^l\ 3-5\n + \1 + #msx, + 'Test the o recallCommand option', + ); +} END { 1 while unlink ($rc_filename, $out_fn); } |