Fix leaking temporary files in tests. RT#59166
[catagits/Catalyst-Devel.git] / t / back_compat.t
index 4e23b7d..0937bab 100644 (file)
@@ -25,7 +25,7 @@ package MyTestHelper;
 use Test::More;
 use File::Temp qw/tempfile/;
 
-my ($fh, $fn) = tempfile;
+my ($fh, $fn) = tempfile( UNLINK => 1 );
 close $fh;
 $helper->render_file('example1',  $fn, { test_var => 'test_val' });
 open $fh, $fn or die $@;