Message-Id: <
200308171052.h7HAqlfo026317@vran.herceg.de>
p4raw-id: //depot/perl@20839
# Dirs
foreach my $dir (@dirs_to_unlink) {
if (-d $dir) {
- rmtree($dir, $DEBUG, 1);
+ rmtree($dir, $DEBUG, 0);
}
}
use strict;
use Test;
-BEGIN { plan tests => 20}
+BEGIN { plan tests => 22}
use File::Spec;
# Will need to check that all files were unlinked correctly
ok( (-f $tempfile ));
push(@files, $tempfile);
+# Test tempfile
+# ..and another with changed permissions (read-only)
+($fh, $tempfile) = tempfile(
+ DIR => $tempdir,
+ );
+chmod 0444, $tempfile;
+
+ok( (-f $tempfile ));
+push(@files, $tempfile);
+
print "# TEMPFILE: Created $tempfile\n";
# and another (with template)