Add a test for s.
authorShlomi Fish <shlomif@shlomifish.org>
Sun, 11 Dec 2011 20:41:35 +0000 (22:41 +0200)
committerRicardo Signes <rjbs@cpan.org>
Fri, 30 Dec 2011 16:54:46 +0000 (11:54 -0500)
lib/perl5db.t

index 280f040..b9a806b 100644 (file)
@@ -28,7 +28,7 @@ BEGIN {
     }
 }
 
-plan(25);
+plan(26);
 
 my $rc_filename = '.perldb';
 
@@ -584,6 +584,32 @@ EOF
         "T command test."
     );
 }
+
+# Test for s.
+{
+    rc(<<'EOF');
+&parse_options("NonStop=0 TTY=db.out LineInfo=db.out");
+
+sub afterinit {
+    push (@DB::typeahead,
+    'b 9',
+    'c',
+    's',
+    q/print "X={$x};dummy={$dummy}\n";/,
+    'q',
+    );
+
+}
+EOF
+
+    my $output = runperl(switches => [ '-d', ], stderr => 1, progfile => '../lib/perl5db/t/disable-breakpoints-1');
+    like($output, qr/
+        X=\{SecondVal\};dummy=\{1\}
+        /msx,
+        'test for s - single step',
+    );
+}
+
 END {
     1 while unlink ($rc_filename, $out_fn);
 }