Don't run optional tests for EPEL builds (avoids need for bootstrapping)

This commit is contained in:
Paul Howarth 2019-10-16 11:25:17 +01:00
parent 9e0119f35d
commit 5b8f957d0e
2 changed files with 13 additions and 5 deletions

View File

@ -1,7 +1,14 @@
# Run extra test
%if ! (0%{?rhel})
%bcond_without perl_Test_CleanNamespaces_enables_extra_test
%else
%bcond_with perl_Test_CleanNamespaces_enables_extra_test
%endif
Name: perl-Test-CleanNamespaces
Summary: Check for uncleaned imports
Version: 0.24
Release: 5%{?dist}
Release: 6%{?dist}
License: GPL+ or Artistic
URL: https://metacpan.org/release/Test-CleanNamespaces
Source0: https://cpan.metacpan.org/modules/by-module/Test/Test-CleanNamespaces-%{version}.tar.gz
@ -48,13 +55,11 @@ BuildRequires: perl(Test::Needs)
BuildRequires: perl(Test::Tester)
BuildRequires: perl(Test::Warnings) >= 0.009
# Optional Test Requirements
%if 0%{!?perl_bootstrap:1}
%if 0%{!?perl_bootstrap:1} && %{with perl_Test_CleanNamespaces_enables_extra_test}
BuildRequires: perl(Class::MOP::Class)
BuildRequires: perl(metaclass)
%if 0%{?fedora}
BuildRequires: perl(Moo) >= 1.000007
BuildRequires: perl(Moo::Role)
%endif
BuildRequires: perl(Moose)
BuildRequires: perl(Moose::Exporter)
BuildRequires: perl(Moose::Role)
@ -85,7 +90,7 @@ find %{buildroot} -type f -name .packlist -delete
%{_fixperms} -c %{buildroot}
%check
make test %{!?perl_bootstrap:AUTOMATED_TESTING=1}
make test AUTOMATED_TESTING=1
%files
%license LICENCE
@ -94,6 +99,9 @@ make test %{!?perl_bootstrap:AUTOMATED_TESTING=1}
%{_mandir}/man3/Test::CleanNamespaces.3*
%changelog
* Wed Oct 16 2019 Paul Howarth <paul@city-fan.org> - 0.24-6
- Don't run optional tests for EPEL builds (avoids need for bootstrapping)
* Fri Jul 26 2019 Fedora Release Engineering <releng@fedoraproject.org> - 0.24-5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild