[libmath-prime-util-perl] 42/43: Don't do test for ST random prime without new Digest::SHA
Partha P. Mukherjee
ppm-guest at moszumanska.debian.org
Thu May 21 18:53:09 UTC 2015
This is an automated email from the git hooks/post-receive script.
ppm-guest pushed a commit to annotated tag v0.40
in repository libmath-prime-util-perl.
commit 047642b11cb978cc413a0b6f617f1dc91a101d2d
Author: Dana Jacobsen <dana at acm.org>
Date: Mon Apr 21 21:33:37 2014 -0700
Don't do test for ST random prime without new Digest::SHA
---
MANIFEST | 1 +
Makefile.PL | 2 +-
t/23-random-certs.t | 9 ++++++++-
3 files changed, 10 insertions(+), 2 deletions(-)
diff --git a/MANIFEST b/MANIFEST
index 486cdc3..d7af73a 100644
--- a/MANIFEST
+++ b/MANIFEST
@@ -147,4 +147,5 @@ xt/test-factor-yafu.pl
xt/test-nextprime-yafu.pl
xt/test-ispower.pl
xt/twin_prime_count.t
+xt/nth_twin_prime.t
.travis.yml
diff --git a/Makefile.PL b/Makefile.PL
index 104d094..df5b144 100644
--- a/Makefile.PL
+++ b/Makefile.PL
@@ -70,7 +70,7 @@ WriteMakefile1(
'Math::Prime::Util::GMP' => 0.16,
'Math::BigInt::GMP' => 0,
'Math::MPFR' => 2.03,
- 'Digest::SHA' => 4.00,
+ 'Digest::SHA' => 5.87,
},
},
test => {
diff --git a/t/23-random-certs.t b/t/23-random-certs.t
index d54773f..23aa7a9 100644
--- a/t/23-random-certs.t
+++ b/t/23-random-certs.t
@@ -11,6 +11,12 @@ use Math::Prime::Util qw/is_prime verify_prime
use Math::BigInt try=>"GMP,Pari";
+my $do_st = 1;
+$do_st = 0 unless eval { require Digest::SHA;
+ my $version = $Digest::SHA::VERSION;
+ $version =~ s/[^\d.]//g;
+ $version >= 4.00; };
+
plan tests => 3*2;
{
@@ -19,7 +25,8 @@ plan tests => 3*2;
ok( verify_prime($cert), " with a valid certificate" );
}
-{
+SKIP: {
+ skip "random Shawe-Taylor prime generation requires Digest::SHA",2 unless $do_st;
my($n,$cert) = random_shawe_taylor_prime_with_cert(80);
ok( is_prime($n), "Random Shawe-Taylor prime returns a prime" );
ok( verify_prime($cert), " with a valid certificate" );
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-perl/packages/libmath-prime-util-perl.git
More information about the Pkg-perl-cvs-commits
mailing list