de8e111
Name:		perl-Test2-Plugin-NoWarnings
f7660e8
Version:	0.08
81dac57
Release:	2%{?dist}
de8e111
Summary:	Fail if tests warn
de8e111
License:	Artistic 2.0
707df56
URL:		https://metacpan.org/release/Test2-Plugin-NoWarnings
707df56
Source0:	https://cpan.metacpan.org/authors/id/D/DR/DROLSKY/Test2-Plugin-NoWarnings-%{version}.tar.gz
de8e111
BuildArch:	noarch
de8e111
# Build
de8e111
BuildRequires:	coreutils
de8e111
BuildRequires:	make
de8e111
BuildRequires:	perl-generators
fa6ad21
BuildRequires:	perl-interpreter
de8e111
BuildRequires:	perl(ExtUtils::MakeMaker) > 6.75
de8e111
# Module Runtime
de8e111
BuildRequires:	perl(Carp)
de8e111
BuildRequires:	perl(parent)
de8e111
BuildRequires:	perl(strict)
fa6ad21
BuildRequires:	perl(Test2) >= 1.302096
de8e111
BuildRequires:	perl(Test2::API)
de8e111
BuildRequires:	perl(Test2::Event)
de8e111
BuildRequires:	perl(Test2::Util::HashBase)
de8e111
BuildRequires:	perl(warnings)
de8e111
# Test Suite
de8e111
BuildRequires:	perl(File::Spec)
6ceee59
BuildRequires:	perl(IPC::Run3)
6ceee59
BuildRequires:	perl(Test2::Require::Module)
fa6ad21
BuildRequires:	perl(Test2::V0)
de8e111
BuildRequires:	perl(Test::More) >= 0.96
de8e111
# Optional Tests
de8e111
BuildRequires:	perl(CPAN::Meta) >= 2.120900
de8e111
BuildRequires:	perl(CPAN::Meta::Prereqs)
de8e111
# Dependencies
de8e111
Requires:	perl(:MODULE_COMPAT_%(eval "`perl -V:version`"; echo $version))
de8e111
de8e111
%description
de8e111
Loading this plugin causes your tests to fail if there are any warnings while
de8e111
they run. Each warning generates a new failing test and the warning content is
de8e111
outputted via diag.
de8e111
de8e111
This module uses $SIG{__WARN__}, so if the code you're testing sets this, then
de8e111
this module will stop working.
de8e111
de8e111
%prep
de8e111
%setup -q -n Test2-Plugin-NoWarnings-%{version}
de8e111
de8e111
%build
de8e111
perl Makefile.PL INSTALLDIRS=vendor NO_PERLLOCAL=1 NO_PACKLIST=1
fa6ad21
%{make_build}
de8e111
de8e111
%install
fa6ad21
%{make_install}
6ceee59
%{_fixperms} -c %{buildroot}
de8e111
de8e111
%check
de8e111
make test
de8e111
de8e111
%files
de8e111
%license LICENSE
fa6ad21
%doc Changes CODE_OF_CONDUCT.md README.md
de8e111
%{perl_vendorlib}/Test2/
de8e111
%{_mandir}/man3/Test2::Event::Warning.3*
de8e111
%{_mandir}/man3/Test2::Plugin::NoWarnings.3*
de8e111
de8e111
%changelog
81dac57
* Thu Jan 30 2020 Fedora Release Engineering <releng@fedoraproject.org> - 0.08-2
81dac57
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
81dac57
f7660e8
* Fri Oct 11 2019 Paul Howarth <paul@city-fan.org> - 0.08-1
f7660e8
- Update to 0.08
f7660e8
  - Use IPC::Run3 instead of Capture::Tiny for all tests, which fixes an issue
f7660e8
    with the 'tap-bug-in-test2.t' on Windows (CPAN RT#129294)
f7660e8
2088188
* Fri Jul 26 2019 Fedora Release Engineering <releng@fedoraproject.org> - 0.07-3
2088188
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
2088188
8376c22
* Fri May 31 2019 Jitka Plesnikova <jplesnik@redhat.com> - 0.07-2
8376c22
- Perl 5.30 rebuild
8376c22
fa6ad21
* Mon Apr 22 2019 Paul Howarth <paul@city-fan.org> - 0.07-1
fa6ad21
- Update to 0.07
fa6ad21
  - Reverted back to using the Warning event type, since the bug in the Test2
fa6ad21
    core that caused this to be a problem has since been fixed
fa6ad21
  - Replaced use of Test2::Bundle::Extended with Test2::V0
fa6ad21
- Package new document CODE_OF_CONDUCT.md
fa6ad21
- Modernize spec using %%{make_build} and %%{make_install}
fa6ad21
bbc5d30
* Sat Feb 02 2019 Fedora Release Engineering <releng@fedoraproject.org> - 0.06-6
bbc5d30
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
bbc5d30
85fe17a
* Fri Jul 13 2018 Fedora Release Engineering <releng@fedoraproject.org> - 0.06-5
85fe17a
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
85fe17a
9421dcb
* Thu Jun 28 2018 Jitka Plesnikova <jplesnik@redhat.com> - 0.06-4
9421dcb
- Perl 5.28 rebuild
9421dcb
e486773
* Fri Feb 09 2018 Fedora Release Engineering <releng@fedoraproject.org> - 0.06-3
e486773
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
e486773
0e07951
* Thu Jul 27 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.06-2
0e07951
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
0e07951
d53f4dc
* Mon Jun 19 2017 Paul Howarth <paul@city-fan.org> - 0.06-1
d53f4dc
- Update to 0.06
d53f4dc
  - Warnings inside a subtest were not emitted as TAP events, breaking the TAP
d53f4dc
    and making for great confusion: this is because of a bug in the core TAP
d53f4dc
    formatter (https://github.com/Test-More/test-more/issues/776); warnings
d53f4dc
    are now emitted as Ok events instead of Warning events
d53f4dc
22eea02
* Mon Jun 05 2017 Jitka Plesnikova <jplesnik@redhat.com> - 0.05-3
22eea02
- Perl 5.26 rebuild
22eea02
d87ebfa
* Sat Feb 11 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.05-2
d87ebfa
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
d87ebfa
614d507
* Tue Nov  8 2016 Paul Howarth <paul@city-fan.org> - 0.05-1
614d507
- Update to 0.05
614d507
  - Skip compile.t on Windows; this test uses IPC::Run3, which doesn't seem to
614d507
    work well on that platform (CPAN RT#118443)
614d507
97acaba
* Thu Oct 27 2016 Paul Howarth <paul@city-fan.org> - 0.04-2
97acaba
- We provide Test2::Event::Warning so we don't need to build-require it
97acaba
0758fd7
* Mon Oct 24 2016 Paul Howarth <paul@city-fan.org> - 0.04-1
0758fd7
- Update to 0.04
0758fd7
  - Load Test2::Event::Warning in the plugin instead of relying on Test2 to do
0758fd7
    it for us; this should avoid the bug fixed in the previous version and
0758fd7
    eliminates the need for the INIT block, which caused its own problems
0758fd7
6ceee59
* Tue Oct 18 2016 Paul Howarth <paul@city-fan.org> - 0.03-1
6ceee59
- Update to 0.03
6ceee59
  - Add the $SIG{__WARN__} hook in an INIT block; we really don't want to
6ceee59
    trigger this because of a compile-time warning, and because of a bug in
6ceee59
    Test::Builder, this can actually cause the warning to be lost entirely
6ceee59
    (https://github.com/Test-More/test-more/issues/729)
6ceee59
  - The Test2::Event::Warning event now returns true for increments_count,
6ceee59
    which means that the test failure caused by a warning will not be output
6ceee59
    as a TAP test line; previously this was just seen as a diag line, which
6ceee59
    could be quite confusing
6ceee59
    (https://github.com/Test-More/test-more/issues/728)
6ceee59
de8e111
* Mon Sep 19 2016 Paul Howarth <paul@city-fan.org> - 0.02-3
de8e111
- Drop unused BR: findutils (#1377228)
de8e111
de8e111
* Mon Sep 19 2016 Paul Howarth <paul@city-fan.org> - 0.02-2
de8e111
- Sanitize for Fedora submission
de8e111
de8e111
* Sun Sep 18 2016 Paul Howarth <paul@city-fan.org> - 0.02-1
de8e111
- Initial RPM version