From: Rafael Garcia-Suarez Date: Thu, 30 Oct 2008 11:34:05 +0000 (+0000) Subject: Add a test for bug #60214 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=e7d3eb55e8d38c7823883a2830dcecfddd108336;p=p5sagit%2Fp5-mst-13.2.git Add a test for bug #60214 p4raw-id: //depot/perl@34661 --- diff --git a/t/op/filetest.t b/t/op/filetest.t index 231242b..97ce3f9 100755 --- a/t/op/filetest.t +++ b/t/op/filetest.t @@ -10,7 +10,7 @@ BEGIN { } use Config; -plan(tests => 24); +plan(tests => 28); ok( -d 'op' ); ok( -f 'TEST' ); @@ -79,6 +79,15 @@ ok( -x -d -x 'op' ); ok( (-s -f 'TEST' > 1), "-s returns real size" ); ok( -f -s 'TEST' == 1 ); +# now with an empty file +open my $fh, ">", "foo"; +close $fh; +ok( -f "foo" ); +is( -s "foo", 0 ); +is( -f -s "foo", 0 ); +is( -s -f "foo", 0 ); +unlink "foo"; + # test that _ is a bareword after filetest operators -f 'TEST';