perl-test-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ge...@apache.org
Subject svn commit: r356781 - /perl/Apache-Test/trunk/lib/Apache/TestConfigPHP.pm
Date Wed, 14 Dec 2005 14:09:38 GMT
Author: geoff
Date: Wed Dec 14 06:09:35 2005
New Revision: 356781

URL: http://svn.apache.org/viewcvs?rev=356781&view=rev
Log:
don't write out t/foo/bar.t if t/foo/bar.php exists

Modified:
    perl/Apache-Test/trunk/lib/Apache/TestConfigPHP.pm

Modified: perl/Apache-Test/trunk/lib/Apache/TestConfigPHP.pm
URL: http://svn.apache.org/viewcvs/perl/Apache-Test/trunk/lib/Apache/TestConfigPHP.pm?rev=356781&r1=356780&r2=356781&view=diff
==============================================================================
--- perl/Apache-Test/trunk/lib/Apache/TestConfigPHP.pm (original)
+++ perl/Apache-Test/trunk/lib/Apache/TestConfigPHP.pm Wed Dec 14 06:09:35 2005
@@ -94,19 +94,21 @@
 
     my $dir = catfile $self->{vars}->{t_dir}, lc $path;
     my $t = catfile $dir, $file;
+    my $php_t = catfile $dir, $test;
     return if -e $t;
 
-    unless (-e $t) {
-        $self->gendir($dir);
-        my $fh = $self->genfile($t);
+    # don't write out foo.t if foo.php already exists
+    return if -e $php_t;
 
-        print $fh <<EOF;
+    $self->gendir($dir);
+    my $fh = $self->genfile($t);
+
+    print $fh <<EOF;
 use Apache::TestRequest 'GET_BODY_ASSERT';
 print GET_BODY_ASSERT "/$location/$test";
 EOF
 
-        close $fh or die "close $t: $!";
-    }
+    close $fh or die "close $t: $!";
 
     # write out an all.t file for the directory
     # that will skip running all PHP test unless have_php



Mime
View raw message