|
|
|
@ -1,14 +1,13 @@
|
|
|
|
|
# RPM version needs 4 digits after the decimal to preserve upgrade path
|
|
|
|
|
%global module_version 0.67
|
|
|
|
|
%global RPM_version %{module_version}00
|
|
|
|
|
# TODO: BR: optional test dependency Unknown::Values if it becomes available
|
|
|
|
|
|
|
|
|
|
Name: perl-Test-Differences
|
|
|
|
|
Version: %{RPM_version}
|
|
|
|
|
Release: 9%{?dist}
|
|
|
|
|
%global cpan_version 0.71
|
|
|
|
|
Version: %(LANG=C printf "%.4f" %{cpan_version})
|
|
|
|
|
Release: 7%{?dist}
|
|
|
|
|
Summary: Test strings and data structures and show differences if not OK
|
|
|
|
|
License: GPL+ or Artistic
|
|
|
|
|
License: GPL-1.0-or-later OR Artistic-1.0-Perl
|
|
|
|
|
URL: https://metacpan.org/release/Test-Differences
|
|
|
|
|
Source0: https://cpan.metacpan.org/modules/by-module/Test/Test-Differences-%{module_version}.tar.gz
|
|
|
|
|
Source0: https://cpan.metacpan.org/modules/by-module/Test/Test-Differences-%{cpan_version}.tar.gz
|
|
|
|
|
BuildArch: noarch
|
|
|
|
|
# Module Build
|
|
|
|
|
BuildRequires: coreutils
|
|
|
|
@ -16,6 +15,7 @@ BuildRequires: findutils
|
|
|
|
|
BuildRequires: make
|
|
|
|
|
BuildRequires: perl-generators
|
|
|
|
|
BuildRequires: perl-interpreter
|
|
|
|
|
BuildRequires: perl(Config)
|
|
|
|
|
BuildRequires: perl(ExtUtils::MakeMaker)
|
|
|
|
|
# Module Runtime
|
|
|
|
|
BuildRequires: perl(B::Deparse)
|
|
|
|
@ -34,18 +34,34 @@ BuildRequires: perl(Test::More) >= 0.88
|
|
|
|
|
BuildRequires: perl(Pod::Coverage) >= 0.18
|
|
|
|
|
BuildRequires: perl(Test::Pod) >= 1.22
|
|
|
|
|
BuildRequires: perl(Test::Pod::Coverage) >= 1.08
|
|
|
|
|
# Explicit Requirements
|
|
|
|
|
Requires: perl(:MODULE_COMPAT_%(eval "`perl -V:version`"; echo $version))
|
|
|
|
|
# Explicit Dependencies
|
|
|
|
|
Requires: perl(B::Deparse)
|
|
|
|
|
Requires: perl(Text::Diff) >= 1.43
|
|
|
|
|
|
|
|
|
|
# Remove private test modules
|
|
|
|
|
%global __requires_exclude %{?__requires_exclude:%__requires_exclude|}^perl\\(Test::Differences::TestUtils::Capture\\)$
|
|
|
|
|
|
|
|
|
|
%description
|
|
|
|
|
When the code you're testing returns multiple lines, records or data
|
|
|
|
|
structures and they're just plain wrong, an equivalent to the Unix
|
|
|
|
|
diff utility may be just what's needed.
|
|
|
|
|
|
|
|
|
|
%package tests
|
|
|
|
|
Summary: Tests for %{name}
|
|
|
|
|
Requires: %{name} = %{?epoch:%{epoch}:}%{version}-%{release}
|
|
|
|
|
Requires: perl-Test-Harness
|
|
|
|
|
|
|
|
|
|
%description tests
|
|
|
|
|
Tests from %{name}. Execute them
|
|
|
|
|
with "%{_libexecdir}/%{name}/test".
|
|
|
|
|
|
|
|
|
|
%prep
|
|
|
|
|
%setup -q -n Test-Differences-%{module_version}
|
|
|
|
|
%setup -q -n Test-Differences-%{cpan_version}
|
|
|
|
|
# Help generators to recognize Perl scripts
|
|
|
|
|
for F in t/*.t; do
|
|
|
|
|
perl -i -MConfig -ple 'print $Config{startperl} if $. == 1 && !s{\A#!.*perl\b}{$Config{startperl}}' "$F"
|
|
|
|
|
chmod +x "$F"
|
|
|
|
|
done
|
|
|
|
|
|
|
|
|
|
%build
|
|
|
|
|
perl Makefile.PL INSTALLDIRS=vendor
|
|
|
|
@ -55,6 +71,18 @@ make %{?_smp_mflags}
|
|
|
|
|
make pure_install DESTDIR=%{buildroot}
|
|
|
|
|
find %{buildroot} -type f -name .packlist -delete
|
|
|
|
|
%{_fixperms} -c %{buildroot}
|
|
|
|
|
# Install tests
|
|
|
|
|
mkdir -p %{buildroot}%{_libexecdir}/%{name}
|
|
|
|
|
cp -a t %{buildroot}%{_libexecdir}/%{name}
|
|
|
|
|
# Remove author tests
|
|
|
|
|
rm -f %{buildroot}%{_libexecdir}/%{name}/t/boilerplate.t
|
|
|
|
|
rm -f %{buildroot}%{_libexecdir}/%{name}/t/pod.t
|
|
|
|
|
rm -f %{buildroot}%{_libexecdir}/%{name}/t/pod-coverage.t
|
|
|
|
|
cat > %{buildroot}%{_libexecdir}/%{name}/test << 'EOF'
|
|
|
|
|
#!/bin/sh
|
|
|
|
|
cd %{_libexecdir}/%{name} && exec prove -I . -j "$(getconf _NPROCESSORS_ONLN)"
|
|
|
|
|
EOF
|
|
|
|
|
chmod +x %{buildroot}%{_libexecdir}/%{name}/test
|
|
|
|
|
|
|
|
|
|
%check
|
|
|
|
|
make test
|
|
|
|
@ -64,13 +92,73 @@ make test
|
|
|
|
|
%{perl_vendorlib}/Test/
|
|
|
|
|
%{_mandir}/man3/Test::Differences.3*
|
|
|
|
|
|
|
|
|
|
%files tests
|
|
|
|
|
%{_libexecdir}/%{name}
|
|
|
|
|
|
|
|
|
|
%changelog
|
|
|
|
|
* Mon Aug 09 2021 Mohan Boddu <mboddu@redhat.com> - 0.6700-9
|
|
|
|
|
- Rebuilt for IMA sigs, glibc 2.34, aarch64 flags
|
|
|
|
|
Related: rhbz#1991688
|
|
|
|
|
* Tue Oct 29 2024 Troy Dawson <tdawson@redhat.com> - 0.7100-7
|
|
|
|
|
- Bump release for October 2024 mass rebuild:
|
|
|
|
|
Resolves: RHEL-64018
|
|
|
|
|
|
|
|
|
|
* Wed Aug 21 2024 Michal Josef Špaček <mspacek@redhat.com> - 0.7100-6
|
|
|
|
|
- Improve version processing
|
|
|
|
|
|
|
|
|
|
* Mon Aug 19 2024 Michal Josef Špaček <mspacek@redhat.com> - 0.7100-5
|
|
|
|
|
- Fix version handling for git commit checks
|
|
|
|
|
- Package tests
|
|
|
|
|
|
|
|
|
|
* Mon Jun 24 2024 Troy Dawson <tdawson@redhat.com> - 0.7100-4
|
|
|
|
|
- Bump release for June 2024 mass rebuild
|
|
|
|
|
|
|
|
|
|
* Thu Jan 25 2024 Fedora Release Engineering <releng@fedoraproject.org> - 0.7100-3
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
* Sun Jan 21 2024 Fedora Release Engineering <releng@fedoraproject.org> - 0.7100-2
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
* Fri Oct 13 2023 Paul Howarth <paul@city-fan.org> - 0.7100-1
|
|
|
|
|
- Update to 0.71
|
|
|
|
|
- Document and test different behavior regarding Booleans in perl 5.38.0
|
|
|
|
|
compared to earlier versions (GH#21)
|
|
|
|
|
|
|
|
|
|
* Fri Jul 21 2023 Fedora Release Engineering <releng@fedoraproject.org> - 0.7000-2
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
* Sat Jul 8 2023 Paul Howarth <paul@city-fan.org> - 0.7000-1
|
|
|
|
|
- Update to 0.70
|
|
|
|
|
- Stop pointless use of taint-mode in tests, so tests pass when perl is
|
|
|
|
|
built without taint support
|
|
|
|
|
|
|
|
|
|
* Fri Jan 20 2023 Fedora Release Engineering <releng@fedoraproject.org> - 0.6900-5
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
* Fri Jul 22 2022 Fedora Release Engineering <releng@fedoraproject.org> - 0.6900-4
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
* Tue May 31 2022 Jitka Plesnikova <jplesnik@redhat.com> - 0.6900-3
|
|
|
|
|
- Perl 5.36 rebuild
|
|
|
|
|
|
|
|
|
|
* Fri Jan 21 2022 Fedora Release Engineering <releng@fedoraproject.org> - 0.6900-2
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
* Sat Jan 8 2022 Paul Howarth <paul@city-fan.org> - 0.6900-1
|
|
|
|
|
- Update to 0.69
|
|
|
|
|
- Special-case Unknown::Values objects in comparisons, as it's better to spit
|
|
|
|
|
out a diagnostic failure than to just die
|
|
|
|
|
- Correct misleading Unicode doco
|
|
|
|
|
|
|
|
|
|
* Fri Jul 23 2021 Fedora Release Engineering <releng@fedoraproject.org> - 0.6800-3
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
* Fri May 21 2021 Jitka Plesnikova <jplesnik@redhat.com> - 0.6800-2
|
|
|
|
|
- Perl 5.34 rebuild
|
|
|
|
|
|
|
|
|
|
* Fri Apr 16 2021 Mohan Boddu <mboddu@redhat.com> - 0.6700-8
|
|
|
|
|
- Rebuilt for RHEL 9 BETA on Apr 15th 2021. Related: rhbz#1947937
|
|
|
|
|
* Wed May 19 2021 Paul Howarth <paul@city-fan.org> - 0.6800-1
|
|
|
|
|
- Update to 0.68
|
|
|
|
|
- Revert undocumented change that was causing unreasonably verbose output
|
|
|
|
|
(GH#5)
|
|
|
|
|
- Improve documentation about text vs. data mode and eq_or_diff_{text,data}
|
|
|
|
|
(GH#8)
|
|
|
|
|
|
|
|
|
|
* Wed Jan 27 2021 Fedora Release Engineering <releng@fedoraproject.org> - 0.6700-7
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
|
|
|
|
|