Make tests subpackage noarch
and improve the package in general.
This commit is contained in:
parent
d5472b93d9
commit
2a9f63c717
1
perl-XML-LibXML.rpmlintrc
Normal file
1
perl-XML-LibXML.rpmlintrc
Normal file
@ -0,0 +1 @@
|
||||
addFilter('-tests\.noarch: W: no-documentation')
|
@ -28,6 +28,7 @@ BuildRequires: make
|
||||
BuildRequires: perl-devel
|
||||
BuildRequires: perl-generators
|
||||
BuildRequires: perl-interpreter
|
||||
BuildRequires: perl(Config)
|
||||
BuildRequires: perl(ExtUtils::MakeMaker) >= 6.76
|
||||
BuildRequires: perl(strict)
|
||||
BuildRequires: perl(warnings)
|
||||
@ -105,6 +106,7 @@ validating XML parser and the high performance DOM implementation.
|
||||
|
||||
%package tests
|
||||
Summary: Tests for %{name}
|
||||
BuildArch: noarch
|
||||
Requires: %{name} = %{?epoch:%{epoch}:}%{version}-%{release}
|
||||
# t/12html.t exhibits ISO-8859-2 charset
|
||||
Requires: glibc-gconv-extra
|
||||
@ -126,6 +128,7 @@ chmod -x *.c
|
||||
for i in Changes; do
|
||||
/usr/bin/iconv -f iso8859-1 -t utf-8 $i > $i.conv && /bin/mv -f $i.conv $i
|
||||
done
|
||||
perl -i -pe 's/\r\n/\n/' t/91unique_key.t
|
||||
|
||||
# Help file to recognise the Perl scripts
|
||||
for F in t/*.t; do
|
||||
@ -146,12 +149,14 @@ find %{buildroot} -type f -name '*.bs' -empty -delete
|
||||
# Install tests
|
||||
mkdir -p %{buildroot}%{_libexecdir}/%{name}
|
||||
cp -a example t test %{buildroot}%{_libexecdir}/%{name}
|
||||
for F in cpan-changes.t 11memory.t pod.t pod-files-presence.t release-kwalitee.t style-trailing-space.t; do
|
||||
rm -f %{buildroot}%{_libexecdir}/%{name}/t/"$F"
|
||||
for F in example/*.pl t/cpan-changes.t t/11memory.t t/pod.t \
|
||||
t/pod-files-presence.t t/release-kwalitee.t t/style-trailing-space.t; do
|
||||
rm -f %{buildroot}%{_libexecdir}/%{name}/"$F"
|
||||
done
|
||||
perl -i -pe 's{example/(testrun.xml)}{/tmp/$1}' %{buildroot}%{_libexecdir}/%{name}/t/03doc.t
|
||||
cat > %{buildroot}%{_libexecdir}/%{name}/tests << 'EOF'
|
||||
#!/bin/sh
|
||||
unset AUTHOR_TESTING RELEASE_TESTING
|
||||
cd %{_libexecdir}/%{name} && THREAD_TEST=0%{?with_thread_test:1} exec prove -I . -j "$(getconf _NPROCESSORS_ONLN)"
|
||||
EOF
|
||||
chmod +x %{buildroot}%{_libexecdir}/%{name}/tests
|
||||
@ -189,6 +194,7 @@ fi
|
||||
%changelog
|
||||
* Fri Jun 25 2021 Petr Pisar <ppisar@redhat.com> - 1:2.0207-3
|
||||
- Build-require glibc-gconv-extra for ISO-8859-2 support in tests
|
||||
- Make tests subpackage noarch
|
||||
|
||||
* Fri May 21 2021 Jitka Plesnikova <jplesnik@redhat.com> - 1:2.0207-2
|
||||
- Perl 5.34 rebuild
|
||||
|
Loading…
Reference in New Issue
Block a user