From 948a4cc165d3c8eacadbdc5e5ebcf52e86d5301e Mon Sep 17 00:00:00 2001 From: Marcel Denia Date: Fri, 21 Aug 2015 21:19:39 +0200 Subject: [PATCH] perl: Skip crypt() tests if unavailable in t/op/tie_fetch_count.t Signed-off-by: Marcel Denia --- ...e_fetch_count_t-handle_missing_crypt.patch | 28 +++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 lang/perl/patches/600-tie_fetch_count_t-handle_missing_crypt.patch diff --git a/lang/perl/patches/600-tie_fetch_count_t-handle_missing_crypt.patch b/lang/perl/patches/600-tie_fetch_count_t-handle_missing_crypt.patch new file mode 100644 index 000000000..32914dde7 --- /dev/null +++ b/lang/perl/patches/600-tie_fetch_count_t-handle_missing_crypt.patch @@ -0,0 +1,28 @@ +Index: perl-5.22.0/t/op/tie_fetch_count.t +=================================================================== +--- perl-5.22.0.orig/t/op/tie_fetch_count.t ++++ perl-5.22.0/t/op/tie_fetch_count.t +@@ -250,12 +250,17 @@ for ([chdir=>''],[chmod=>'0,'],[chown=>' + check_count "$op $args\\\$tied_glob$postargs"; + } + +-$dummy = crypt $var,0; check_count 'crypt $tied, ...'; +-$dummy = crypt 0,$var; check_count 'crypt ..., $tied'; +-$var = substr(chr 256,0,0); +-$dummy = crypt $var,0; check_count 'crypt $tied_utf8, ...'; +-$var = substr(chr 256,0,0); +-$dummy = crypt 0,$var; check_count 'crypt ..., $tied_utf8'; ++SKIP: { ++ use Config; ++ skip "crypt() is unavailable", 4, unless defined $Config{'d_crypt'}; ++ ++ $dummy = crypt $var,0; check_count 'crypt $tied, ...'; ++ $dummy = crypt 0,$var; check_count 'crypt ..., $tied'; ++ $var = substr(chr 256,0,0); ++ $dummy = crypt $var,0; check_count 'crypt $tied_utf8, ...'; ++ $var = substr(chr 256,0,0); ++ $dummy = crypt 0,$var; check_count 'crypt ..., $tied_utf8'; ++} + + SKIP: + {