X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=lib%2Fperl5db.t;h=9c95a5b84ca49f04c9d0d49051d9dd9ef7901034;hb=3e7dd34d07ec3fbcf1e108a3270d6009e068e8eb;hp=8735e87a447c840ca7e6340abc4e3af88e263319;hpb=635f2c9e92f8c492655e9f22e378ee92d3368ced;p=p5sagit%2Fp5-mst-13.2.git diff --git a/lib/perl5db.t b/lib/perl5db.t index 8735e87..9c95a5b 100644 --- a/lib/perl5db.t +++ b/lib/perl5db.t @@ -22,25 +22,34 @@ sub rc { open RC, ">", ".perldb" or die $!; print RC @_; close(RC); + # overly permissive perms gives "Must not source insecure rcfile" + # and hangs at the DB(1> prompt + chmod 0644, ".perldb"; } +my $target = '../lib/perl5db/t/eval-line-bug'; + rc( qq| - &parse_options("NonStop=0 TTY=/dev/null LineInfo=db.out"); + &parse_options("NonStop=0 TTY=db.out LineInfo=db.out"); \n|, qq| sub afterinit { push(\@DB::typeahead, - "DB::print_lineinfo(\@{'main::_ [ '-d' ], progfile => '../lib/perl5db/eval-line-bug'); +runperl(switches => [ '-d' ], progfile => $target); my $contents; { @@ -50,12 +59,12 @@ my $contents; close(I); } -like($contents, qr/factorial/, +like($contents, qr/sub factorial/, 'The ${main::_