Subject: | [PATCH] Handle systems without crypt() |
This is needed to get the module working on Android.
Subject: | 0001-Handle-systems-without-crypt.patch |
From f7569c11ea7190d60b116bd808785920fa109cb2 Mon Sep 17 00:00:00 2001
From: Brian Fraser <fraserbn@gmail.com>
Date: Sun, 3 Aug 2014 21:00:16 +0200
Subject: [PATCH] Handle systems without crypt()
---
t/basic.t | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/t/basic.t b/t/basic.t
index b4fd40e..6bb315e 100644
--- a/t/basic.t
+++ b/t/basic.t
@@ -3,6 +3,7 @@
use strict;
use warnings;
+use Config;
use Test::More tests => 15;
use ok "MooseX::Types::Authen::Passphrase";
@@ -41,7 +42,8 @@ use ok "MooseX::Types::Authen::Passphrase";
ok( !$u->check_password("bar"), "password checking" );
}
-{
+SKIP: {
+ skip("crypt() not available on this system", 3) unless $Config{d_crypt};
my $u = User->new( pass => crypt("foo", "bar") );
isa_ok( $u->pass, "Authen::Passphrase" );
--
1.7.12.4 (Apple Git-37)