Permalink
Browse files

t/C-COMPILED/template.pl: revert optim specific bin names

we need to check in the tests for $0 for comparing diagnostics
  • Loading branch information...
1 parent 5c8d354 commit 50218f738e89adb940dee683322bebc63883c546 @rurban committed Feb 14, 2014
Showing with 12 additions and 9 deletions.
  1. +10 −8 t/C-COMPILED/template.pl
  2. +1 −1 t/CORE/io/utf8.t
  3. +1 −0 t/CORE/op/chdir.t
@@ -64,12 +64,14 @@
local $ENV{BC_OPT} = $optimization;
my $b = $optimization; # protect against parallel test name clashes
- $b =~ s/-(D.*|f.*|v),//g;
- $b =~ s/-/_/g;
- $b =~ s/[, ]//g;
- $b =~ s/_O0$//;
- $b = lc($b);
+ #$b =~ s/-(D.*|f.*|v),//g;
+ #$b =~ s/-/_/g;
+ #$b =~ s/[, ]//g;
+ #$b =~ s/_O0$//;
+ #$b = lc($b);
+ $b = ''; # need to check $0 diagnostics
( $c_file = $file_to_test ) =~ s/\.t$/$b.c/;
+ $b = '.bin'; # need to check $0 diagnostics
( $bin_file = $file_to_test ) =~ s/\.t$/$b/;
unlink $bin_file, $c_file;
@@ -148,8 +150,8 @@
ok( !scalar @{ $parser->{failed} }, "Test results:" );
print " $_\n" foreach ( split( "\n", $out ) );
- if (!ok( !scalar @{ $parser->{failed} }, "No test failures" )) {
- note( "Failed tests: " . join( ", ", @{ $parser->{failed} } ) );
+ if (!ok( !scalar @{ $parser->{failed} }, "No test failures $optimization" )) {
+ note( "Failed $optimization tests: " . join( ", ", @{ $parser->{failed} } ) );
$ENV{BC_DEVELOPING} = 1; # keep temp files
}
@@ -163,7 +165,7 @@
}
local $TODO = "tests unexpectedly passing" if scalar @{ $parser->{todo_passed} };
- if (!ok( !scalar @{ $parser->{todo_passed} }, "No TODO tests passed" )) {
+ if (!ok( !scalar @{ $parser->{todo_passed} }, "No TODO tests passed $optimization" )) {
note( "TODO Passed: " . join( ", ", @{ $parser->{todo_passed} } ) );
$ENV{BC_DEVELOPING} = 1; # keep temp files
}
View
@@ -1,6 +1,6 @@
#!./perl
-BEGIN {
+INIT {
require 't/CORE/test.pl';
}
View
@@ -158,6 +158,7 @@ sub check_env {
my $program_name = $0;
$program_name =~ s/\.bin$/.t/;
+ $program_name =~ s{^\./}{};
is( $warning, <<WARNING, ' got uninit & deprecation warning' );
Use of uninitialized value in chdir at $program_name line 64.

0 comments on commit 50218f7

Please sign in to comment.