diff --git a/perl-CPAN.spec b/perl-CPAN.spec index 422e319..1460d0c 100644 --- a/perl-CPAN.spec +++ b/perl-CPAN.spec @@ -1,6 +1,9 @@ # Don not run gnupg1 tests by default, they need network access # (Socket::inet_aton('pool.sks-keyservers.net')). %bcond_with perl_CPAN_enables_gnupg_test +# Run optional test +%bcond_without perl_CPAN_enables_optional_test + %global cpan_version 2.16 Name: perl-CPAN @@ -108,6 +111,7 @@ BuildRequires: perl(FindBin) BuildRequires: perl(Pod::Usage) BuildRequires: perl(Test::More) +%if %{with perl_CPAN_enables_optional_test} # Optional tests: %if %{with perl_CPAN_enables_gnupg_test} BuildRequires: %{_bindir}/gpg @@ -136,6 +140,7 @@ BuildRequires: perl(Test::Pod) >= 1.00 BuildRequires: perl(Test::Pod::Coverage) >= 0.18 BuildRequires: perl(YAML) >= 0.60 %endif +%endif Requires: make Requires: perl(:MODULE_COMPAT_%(eval "`perl -V:version`"; echo $version))