Introduce build-condition for optional tests

This commit is contained in:
Petr Písař 2017-04-28 12:18:40 +02:00
parent 775c10432c
commit e6ae51897a

View File

@ -1,3 +1,5 @@
%{bcond_without perl_Try_Tiny_enables_optional_test}
Name: perl-Try-Tiny
Summary: Minimal try/catch with proper localization of $@
Version: 0.28
@ -23,11 +25,13 @@ BuildRequires: perl(warnings)
# Test Suite
BuildRequires: perl(File::Spec)
BuildRequires: perl(Test::More)
%if %{with perl_Try_Tiny_enables_optional_test}
# Optional Tests
BuildRequires: perl(Capture::Tiny) >= 0.12
BuildRequires: perl(CPAN::Meta) >= 2.120900
BuildRequires: perl(CPAN::Meta::Check) >= 0.011
BuildRequires: perl(CPAN::Meta::Requirements)
%endif
# Runtime
Requires: perl(:MODULE_COMPAT_%(eval "`perl -V:version`"; echo $version))
Requires: perl(Sub::Util)