From: Marius Gavrilescu Date: Sat, 22 Apr 2017 11:01:06 +0000 (+0300) Subject: Tests require recent version of File::Spec::Functions X-Git-Tag: 0.001004~1 X-Git-Url: http://git.ieval.ro/?p=mafia.git;a=commitdiff_plain;h=78e7a0594cc773f3af79a430d248116d388ba43d Tests require recent version of File::Spec::Functions --- diff --git a/Makefile.PL b/Makefile.PL index e1dcb27..f2bca8c 100644 --- a/Makefile.PL +++ b/Makefile.PL @@ -1,6 +1,8 @@ -use 5.014000; +use 5.010001; use ExtUtils::MakeMaker; +my $has_tr = $ExtUtils::MakeMaker::VERSION >= 6.64; + WriteMakefile( NAME => 'Mafia', VERSION_FROM => 'lib/Mafia.pm', @@ -9,6 +11,12 @@ WriteMakefile( MIN_PERL_VERSION => '5.10.1', LICENSE => 'perl', SIGN => 1, + (TEST_REQUIRES => { + qw/File::Spec::Functions 3.62/, + }) x $has_tr, + (PREREQ_PM => { + qw/File::Spec::Functions 3.62/, + }) x !$has_tr, META_MERGE => { dynamic_config => 0, resources => { diff --git a/t/examples.t b/t/examples.t index 56423e7..39af49a 100644 --- a/t/examples.t +++ b/t/examples.t @@ -17,7 +17,7 @@ for my $example (@examples) { open STDOUT, '>', \$out; clean; - do rel2abs $example; + do(rel2abs($example)); $example =~ s/\.pl$//; my $ok = join '', IO::File->new("$example.out", '<')->getlines; is $out, $ok, substr $example, length 't/examples/'