Here's a patch to use File::Temp->newdir() instead of File::Tempdir::new()
diff --git a/META.yml b/META.yml
index 511ba93..009a172 100644
--- a/META.yml
+++ b/META.yml
@@ -6,7 +6,7 @@ license: perl
generated_by: ExtUtils::MakeMaker version 6.36_01
distribution_type: module
requires:
- File::Tempdir: 0.02
+ File::Temp: 0.22
Getopt::Long: 2.34
Pod::Usage: 1.3
Test::More: 0
diff --git a/Makefile.PL b/Makefile.PL
index d5ce6d0..62c9375 100644
--- a/Makefile.PL
+++ b/Makefile.PL
@@ -24,7 +24,7 @@ my %ARGS = (
EXE_FILES => [],
PREREQ_PM => {
'Test::More' => 0,
- 'File::Tempdir' => '0.02',
+ 'File::Temp' => '0.22', # XXX or perhaps earlier versions?
},
dist => { COMPRESS => 'gzip -9f', SUFFIX => 'gz', },
clean => { FILES => 'File-Find-Parallel-*' },
diff --git a/lib/File/Find/Parallel.pm b/lib/File/Find/Parallel.pm
index 4857a95..bea6fbb 100644
--- a/lib/File/Find/Parallel.pm
+++ b/lib/File/Find/Parallel.pm
@@ -298,7 +298,7 @@ are built.
=head1 DEPENDENCIES
-The tests require L<File::Tempdir> and optionally L<Test::Pod::Coverage>
+The tests require L<File::Temp> and optionally L<Test::Pod::Coverage>
and L<Test::Pod>.
The L<lncopies> script requires L<Getopt::Long> and L<Pod::Usage>.
diff --git a/t/20.iter.t b/t/20.iter.t
index 2f4fee1..25ab2b2 100644
--- a/t/20.iter.t
+++ b/t/20.iter.t
@@ -2,7 +2,7 @@
use strict;
use warnings;
-use File::Tempdir;
+use File::Temp;
use File::Path;
use File::Spec;
use File::Find::Parallel;
@@ -103,9 +103,9 @@ for my $test ( @schedule ) {
# Setup
for my $create ( @{ $test->{create} } ) {
- my $td = File::Tempdir->new();
+ my $td = File::Temp->newdir();
push @temp, $td; # stop it going out of scope
- my $root = $td->name;
+ my $root = $td->dirname;
$ffp->add_dirs( $root );
# Make directories