X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=t%2Fop%2Fread.t;h=23f1b51a2c69ac912d77453a79aadf3a6d0f059b;hb=84281c3142b669e898404773f536776423f8c11b;hp=99a62166ced80ab4b0030120694257c36df2a6e1;hpb=846e3505506e5ca6188404fe694911fd9e543b20;p=p5sagit%2Fp5-mst-13.2.git diff --git a/t/op/read.t b/t/op/read.t index 99a6216..23f1b51 100755 --- a/t/op/read.t +++ b/t/op/read.t @@ -1,7 +1,5 @@ #!./perl -# $RCSfile: read.t,v $$Revision: 4.1 $$Date: 92/08/07 18:28:17 $ - BEGIN { chdir 't'; @INC = '../lib'; @@ -33,9 +31,7 @@ my $has_perlio = !eval { !$Config::Config{useperlio} }; -my $tmpfile = 'Op_read.tmp'; - -END { 1 while unlink $tmpfile } +my $tmpfile = tempfile(); my (@values, @buffers) = ('', ''); @@ -58,7 +54,6 @@ foreach my $value (@values) { skip "Needs :utf8 layer but no perlio", 2 * @offsets * @lengths if $utf8 and !$has_perlio; - 1 while unlink $tmpfile; open FH, ">$tmpfile" or die "Can't open $tmpfile: $!"; binmode FH, "utf8" if $utf8; print FH $value;