Update to 0.40

- New upstream release 0.40
  - Test::Class failed on Test::Builder 0.99 (CPAN RT#89473)
- This release by RJBS -> update source URL
- Drop now-redundant test patch
- Use a patch to fix the documentation character encoding
- Drop %defattr, redundant since rpm 4.4
- Make the %files list more explicit
- No need to remove empty directories from the buildroot
- Don't use macros for commands
- Work around annoying noise from TAP::Parser::SourceHandler::Perl version 3.28
  (CPAN RT#85106)
epel9
Paul Howarth 11 years ago
parent bfd2413913
commit bcac0eda35

5
.gitignore vendored

@ -1,4 +1 @@
Test-Class-0.33.tar.gz /Test-Class-[0-9.]*.tar.gz
/Test-Class-0.36.tar.gz
/Test-Class-0.38.tar.gz
/Test-Class-0.39.tar.gz

@ -1,84 +0,0 @@
From eceb5cde6609858e700cbeb2fd787109ce263e9c Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Petr=20P=C3=ADsa=C5=99?= <ppisar@redhat.com>
Date: Wed, 7 Aug 2013 10:58:43 +0200
Subject: [PATCH] Adjust to Test-Simple 0.98_04
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
<https://rt.cpan.org/Public/Bug/Display.html?id=85004>
Signed-off-by: Petr Písař <ppisar@redhat.com>
---
t/fail2.t | 19 ++++++++++++++-----
t/runtests_die.t | 17 +++++++++++++----
2 files changed, 27 insertions(+), 9 deletions(-)
diff --git a/t/fail2.t b/t/fail2.t
index 0231685..26d6f54 100644
--- a/t/fail2.t
+++ b/t/fail2.t
@@ -23,14 +23,23 @@ sub _test_new : Test(3) {
package main;
$ENV{TEST_VERBOSE}=0;
-my $identifier = ($Test::More::VERSION < 0.88) ? 'object' : 'thing';
+my $identifier = 'undef';
+if ($Test::More::VERSION < 0.88) {
+ $identifier = 'The object';
+} elsif ($Test::More::VERSION < 0.9804) {
+ $identifier = 'The thing';
+}
+my $quote = q{'};
+if ($Test::More::VERSION < 0.9804) {
+ $quote = q{};
+}
-test_out("not ok 1 - The $identifier isa Object");
+test_out("not ok 1 - $identifier isa $quote" . "Object" . "$quote");
test_out("not ok 2 - cannot create Objects");
-test_fail(-12);
+test_fail(-21);
test_err( "# (in Object::Test->_test_new)" );
-test_err(qr/#\s+The $identifier isn't defined\n/);
-test_fail(-15);
+test_err(qr/#\s+\Q$identifier\E isn't defined\n/);
+test_fail(-24);
test_err( "# (in Object::Test->_test_new)" );
Object::Test->runtests;
diff --git a/t/runtests_die.t b/t/runtests_die.t
index 238ec21..953bd1d 100755
--- a/t/runtests_die.t
+++ b/t/runtests_die.t
@@ -21,14 +21,23 @@ use Test::Builder::Tester tests => 1;
$ENV{TEST_VERBOSE}=0;
my $filename = sub { return (caller)[1] }->();
-my $identifier = ($Test::More::VERSION < 0.88) ? 'object' : 'thing';
+my $identifier = 'undef';
+if ($Test::More::VERSION < 0.88) {
+ $identifier = 'The object';
+} elsif ($Test::More::VERSION < 0.9804) {
+ $identifier = 'The thing';
+}
+my $quote = q{'};
+if ($Test::More::VERSION < 0.9804) {
+ $quote = q{};
+}
-test_out( "not ok 1 - The $identifier isa Object");
+test_out( "not ok 1 - $identifier isa $quote" . "Object" . "$quote");
test_err( "# Failed test ($filename at line 15)");
test_err( "# (in Foo->test_object)" );
-test_err( "# The $identifier isn't defined");
+test_err( "# $identifier isn't defined");
test_out( "not ok 2 - test_object died (could not create object)");
-test_err( "# Failed test ($filename at line 33)");
+test_err( "# Failed test ($filename at line 42)");
test_err( "# (in Foo->test_object)" );
Foo->runtests;
test_test("early die handled");
--
1.8.1.4

@ -0,0 +1,11 @@
--- Changes
+++ Changes
@@ -175,7 +175,7 @@
- Fixed the installation errors that everybody has been rightly
complaining about for the last year:
- Prerequisities in requires, not build_requires
- - Tests no longer rely on hard coded test output (thanks Martn
+ - Tests no longer rely on hard coded test output (thanks Martín
Ferrari and Nicholas Clark for patches)
- Require appropriate version of Test::Exception
- Added link to del.icio.us perl+testing links in POD

@ -1,15 +1,13 @@
Name: perl-Test-Class Name: perl-Test-Class
Version: 0.39 Version: 0.40
Release: 3%{?dist} Release: 1%{?dist}
Summary: Easily create test classes in an xUnit/JUnit style Summary: Easily create test classes in an xUnit/JUnit style
License: GPL+ or Artistic License: GPL+ or Artistic
Group: Development/Libraries Group: Development/Libraries
URL: http://search.cpan.org/dist/Test-Class/ URL: http://search.cpan.org/dist/Test-Class/
Source0: http://www.cpan.org/authors/id/A/AD/ADIE/Test-Class-%{version}.tar.gz Source0: http://www.cpan.org/authors/id/R/RJ/RJBS/Test-Class-%{version}.tar.gz
# Adjust to Test-Simple 0.98_04, bug #992734, CPAN RT#85004 Patch0: perl-Test-Class-UTF8.patch
Patch0: Test-Class-0.39-Adjust-to-Test-Simple-0.98_04.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(id -nu)
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildArch: noarch BuildArch: noarch
BuildRequires: perl BuildRequires: perl
BuildRequires: perl(Module::Build) BuildRequires: perl(Module::Build)
@ -34,7 +32,7 @@ BuildRequires: perl(Test::Exception) >= 0.25
BuildRequires: perl(Test::More) >= 0.78 BuildRequires: perl(Test::More) >= 0.78
# Optional tests: # Optional tests:
BuildRequires: perl(Contextual::Return) BuildRequires: perl(Contextual::Return)
Requires: perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version)) Requires: perl(:MODULE_COMPAT_%(eval "`perl -V:version`"; echo $version))
Requires: perl(Attribute::Handlers) >= 0.77 Requires: perl(Attribute::Handlers) >= 0.77
Requires: perl(MRO::Compat) >= 0.11 Requires: perl(MRO::Compat) >= 0.11
Requires: perl(Storable) >= 2.04 Requires: perl(Storable) >= 2.04
@ -49,40 +47,52 @@ your code in an xUnit style.
%prep %prep
%setup -q -n Test-Class-%{version} %setup -q -n Test-Class-%{version}
%patch0 -p1
# Fix up broken permissions # Fix up broken permissions
find -type f -exec chmod -x {} \; find -type f -exec chmod -c -x {} \;
# There's a non-ISO char, iconv isn't able to convert # Fix character encoding in documentation
%{__perl} -pi -e 's/Mart.*n/Martín/' < Changes > Changes~ %patch0
mv Changes~ Changes
%build %build
%{__perl} Build.PL installdirs=vendor perl Build.PL installdirs=vendor
./Build ./Build
%install %install
rm -rf $RPM_BUILD_ROOT rm -rf $RPM_BUILD_ROOT
./Build install destdir=$RPM_BUILD_ROOT create_packlist=0 ./Build install destdir=$RPM_BUILD_ROOT create_packlist=0
find $RPM_BUILD_ROOT -depth -type d -exec rmdir {} 2>/dev/null \; %{_fixperms} $RPM_BUILD_ROOT
%{_fixperms} $RPM_BUILD_ROOT/*
%check %check
# Avoid annoying noise from TAP::Parser::SourceHandler::Perl version 3.28 (CPAN RT#85106)
export PERL5LIB="$(pwd)/no-such-directory"
./Build test ./Build test
%clean %clean
rm -rf $RPM_BUILD_ROOT rm -rf $RPM_BUILD_ROOT
%files %files
%defattr(-,root,root,-)
%doc Changes LICENSE README %doc Changes LICENSE README
%{perl_vendorlib}/* %{perl_vendorlib}/Test/
%{_mandir}/man3/* %{_mandir}/man3/Test::Class.3pm*
%{_mandir}/man3/Test::Class::Load.3pm*
%{_mandir}/man3/Test::Class::MethodInfo.3pm*
%changelog %changelog
* Fri Nov 15 2013 Paul Howarth <paul@city-fan.org> - 0.40-1
- Update to 0.40
- Test::Class failed on Test::Builder 0.99 (CPAN RT#89473)
- This release by RJBS -> update source URL
- Drop now-redundant test patch
- Use a patch to fix the documentation character encoding
- Drop %%defattr, redundant since rpm 4.4
- Make the %%files list more explicit
- No need to remove empty directories from the buildroot
- Don't use macros for commands
- Work around annoying noise from TAP::Parser::SourceHandler::Perl version 3.28
(CPAN RT#85106)
* Sun Aug 04 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.39-3 * Sun Aug 04 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.39-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild - Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
- Adjust to Test-Simple 0.98_04 (bug #992734) - Adjust to Test-Simple 0.98_04 (bug #992734)

@ -1 +1 @@
f296e57ede695bff76e4f1336e4c49d3 Test-Class-0.39.tar.gz 22e4387daec4117c8a56767790059951 Test-Class-0.40.tar.gz

Loading…
Cancel
Save