Do not run extra tests on RHEL

This commit is contained in:
Paul Howarth 2019-09-05 14:38:29 +01:00
parent 84c819aa55
commit 18fc903af9
1 changed files with 17 additions and 5 deletions

View File

@ -1,6 +1,13 @@
# Run author tests
%if ! (0%{?rhel})
%bcond_without perl_Perl_Critic_enables_extra_test
%else
%bcond_with perl_Perl_Critic_enables_extra_test
%endif
Name: perl-Perl-Critic
Version: 1.134
Release: 4%{?dist}
Release: 5%{?dist}
Summary: Critique Perl source code for best-practices
License: GPL+ or Artistic
URL: https://metacpan.org/release/Perl-Critic
@ -71,14 +78,12 @@ BuildRequires: perl(Test::More)
# We don't run the author tests when bootstrapping due to circular dependencies
# Test::Perl::Critic obviously pulls in Perl::Critic too
%if 0%{!?perl_bootstrap:1}
%if 0%{!?perl_bootstrap:1} && %{with perl_Perl_Critic_enables_extra_test}
BuildRequires: perl(Devel::EnforceEncapsulation)
BuildRequires: perl(Perl::Critic::Policy::Editor::RequireEmacsFileVariables)
BuildRequires: perl(Perl::Critic::Policy::ErrorHandling::RequireUseOfExceptions)
BuildRequires: perl(Perl::Critic::Policy::Miscellanea::RequireRcsKeywords)
%if ! (0%{?rhel:1})
BuildRequires: perl(Test::Kwalitee) >= 1.15
%endif
BuildRequires: perl(Test::Perl::Critic)
BuildRequires: perl(Test::Pod) >= 1.00
BuildRequires: perl(Test::Pod::Coverage) >= 1.04
@ -134,7 +139,11 @@ perl Build.PL --installdirs=vendor
%{_fixperms} -c %{buildroot}
%check
LC_ALL=en_US ./Build %{!?perl_bootstrap:author}test
%if 0%{!?perl_bootstrap:1} && %{with perl_Perl_Critic_enables_extra_test}
LC_ALL=en_US ./Build authortest
%else
LC_ALL=en_US ./Build test
%endif
%files
%if 0%{?_licensedir:1}
@ -153,6 +162,9 @@ LC_ALL=en_US ./Build %{!?perl_bootstrap:author}test
%{_mandir}/man3/Test::Perl::Critic::Policy.3*
%changelog
* Thu Sep 5 2019 Paul Howarth <paul@city-fan.org> - 1.134-5
- Do not run extra tests on RHEL
* Fri Jul 26 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.134-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild