Here is a patch that will fix the t/07-recurseprune.t test on Windows.
For the other test, without loading a module to really manipulate
permissions on Windows, the test either needs to be changed to test the
method without looking at permissions or just skip the test on Windows;
chmod 0000 does not prevent a file/folder from being read on Windows.
From d451daeea55bb95e1a5a2f4aaaeeb6a189efaed4 Mon Sep 17 00:00:00 2001
From: Douglas Christopher Wilson <doug@somethingdoug.com>
Date: Mon, 10 Dec 2012 15:26:52 -0500
Subject: [PATCH] Platform-independent paths in t/07-recurseprune.t
---
t/07-recurseprune.t | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/t/07-recurseprune.t b/t/07-recurseprune.t
index a5f2c29..2061378 100644
--- a/t/07-recurseprune.t
+++ b/t/07-recurseprune.t
@@ -35,7 +35,7 @@ my $a = $tmp->subdir('a');
$a->recurse(
callback => sub{
my $item = shift;
- my $rel_item = $item->relative($tmp);
+ my $rel_item = $item->relative($tmp)->as_foreign('Unix');
$visited{$rel_item} = 1;
});
@@ -54,7 +54,7 @@ ok( $a->PRUNE );
$a->recurse(
callback => sub{
my $item = shift;
- my $rel_item = $item->relative($tmp);
+ my $rel_item = $item->relative($tmp)->as_foreign('Unix');
$visited{$rel_item} = 1;
return $item->PRUNE if $rel_item eq 'a/b';
});
@@ -75,7 +75,7 @@ is( $a->PRUNE, Path::Class::Entity::PRUNE() );
$a->recurse(
callback => sub{
my $item = shift;
- my $rel_item = $item->relative($tmp);
+ my $rel_item = $item->relative($tmp)->as_foreign('Unix');
$visited{$rel_item} = 1;
return Path::Class::Entity::PRUNE() if $rel_item eq 'a/c';
});
--
1.7.11.msysgit.1