# though we aren't using it here (yet).
return 1;
}
- failed($got, $pattern);
+ failed($got, $pattern, $name);
}
sub is {
print "ok $test - $name\n";
return 1;
}
- failed($got, "'$expect'");
+ failed($got, "'$expect'", $name);
}
my $filename = "multiline$$";
# though we aren't using it here (yet).
return 1;
}
- failed($got, $pattern);
+ failed($got, $pattern, $name);
}
sub is {
print "ok $test - $name\n";
return 1;
}
- failed($got, "'$expect'");
+ failed($got, "'$expect'", $name);
}
sub isnt {
print "ok $test - $name\n";
return 1;
}
- failed($got, "not '$expect'");
+ failed($got, "not '$expect'", $name);
}
sub can_ok {
eval "qx('unqualified'".
($^O eq 'MSWin32' ? " 2>&1)" : ")");
TODO: {
- local $::TODO = $^O eq 'MSWin32' ? "Tainting of PATH not working of Windows" : $::TODO;
- like( $@, qr/^Insecure/, "qx('unqualified') doesn't work" );
+ local $::TODO = $^O eq 'MSWin32' ? "Tainting of PATH not working of Windows" : $::TODO;
+ like( $@, qr/^Insecure/, "qx('unqualified') doesn't work" );
}
is( main::qx('main'), "qx-main", "main::qx() is func" );
is( &qx('amper'), "qx-amper", "&qx() is func" );
my $test = 0;
sub failed {
- my ($got, $expected) = @_;
+ my ($got, $expected, $name) = @_;
- print "not ok $test\n";
+ print "not ok $test - $name\n";
my @caller = caller(1);
print "# Failed test at $caller[1] line $caller[2]\n";
if (defined $got) {
# though we aren't using it here (yet).
return 1;
}
- failed($got, $pattern);
+ failed($got, $pattern, $name);
}
sub is {
print "ok $test\n";
return 1;
}
- failed($got, "'$expect'");
+ failed($got, "'$expect'", $name);
} else {
if (!defined $got) {
print "ok $test\n";
return 1;
}
- failed($got, 'undef');
+ failed($got, 'undef', $name);
}
}