return "at $caller[1] line $caller[2]";
}
+# DON'T use this for matches. Use like() instead.
sub ok {
my ($pass, $name, @mess) = @_;
_ok($pass, _where(), $name, @mess);
foreach (@$args) {
# In VMS protect with doublequotes because otherwise
# DCL will lowercase -- unless already doublequoted.
- $_ = q(").$_.q(") if $is_vms && !/^\"/;
+ $_ = q(").$_.q(") if $is_vms && !/^\"/ && length($_) > 0;
$$runperl .= ' ' . $_;
}
}
print STDERR "# STATUS: $status\n";
}
- ($name) = $prog =~ /^(.{1,35})/ unless $name;
+ # Use the first line of the program as a name if none was given
+ unless( $name ) {
+ ($first_line, $name) = $prog =~ /^((.{1,50}).*)/;
+ $name .= '...' if length $first_line > length $name;
+ }
_ok($pass, _where(), "fresh_perl - $name");
}