From 12f1669fbe98ce0d45bdc40a065632c53dc919a6 Mon Sep 17 00:00:00 2001 From: Shlomi Fish Date: Sat, 15 Sep 2012 16:54:24 +0300 Subject: [PATCH] Test the m command. --- lib/perl5db.t | 28 +++++++++++++++++++++++++++- 1 file changed, 27 insertions(+), 1 deletion(-) diff --git a/lib/perl5db.t b/lib/perl5db.t index 2bb8ffd..0e00d49 100644 --- a/lib/perl5db.t +++ b/lib/perl5db.t @@ -28,7 +28,7 @@ BEGIN { } } -plan(84); +plan(86); my $rc_filename = '.perldb'; @@ -2049,6 +2049,32 @@ sub _calc_trace_wrapper ); } +# Add a test for H (without arguments) +{ + my $wrapper = DebugWrap->new( + { + cmds => + [ + 'm main', + 'q', + ], + prog => '../lib/perl5db/t/disable-breakpoints-1', + } + ); + + $wrapper->contents_like(qr# + ^via\ UNIVERSAL:\ DOES$ + #msx, + "Test m for main - 1", + ); + + $wrapper->contents_like(qr# + ^via\ UNIVERSAL:\ can$ + #msx, + "Test m for main - 2", + ); +} + END { 1 while unlink ($rc_filename, $out_fn); } -- 2.7.4