diff --git a/.fmf/version b/.fmf/version new file mode 100644 index 0000000..d00491f --- /dev/null +++ b/.fmf/version @@ -0,0 +1 @@ +1 diff --git a/gating.yaml b/gating.yaml new file mode 100644 index 0000000..648918d --- /dev/null +++ b/gating.yaml @@ -0,0 +1,6 @@ +--- !Policy +product_versions: + - rhel-9 +decision_context: osci_compose_gate +rules: + - !PassingTestCaseRule {test_case_name: osci.brew-build.tier0.functional} diff --git a/perl-Module-Signature.spec b/perl-Module-Signature.spec index 0f9fa15..85dc63a 100644 --- a/perl-Module-Signature.spec +++ b/perl-Module-Signature.spec @@ -2,8 +2,8 @@ %global gnupghome %(mktemp --directory) Name: perl-Module-Signature -Version: 0.87 -Release: 2%{?dist} +Version: 0.88 +Release: 1%{?dist} Summary: CPAN signature management utilities and modules License: CC0 URL: https://metacpan.org/release/Module-Signature @@ -58,6 +58,15 @@ Suggests: perl(PAR::Dist) This package contains a command line tool and module for checking and creating SIGNATURE files for Perl CPAN distributions. +%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 Module-Signature-%{version} @@ -65,6 +74,12 @@ SIGNATURE files for Perl CPAN distributions. rm -r ./inc/* sed -i -e '/^inc\//d' MANIFEST +# Help generators to recognize Perl scripts +for F in t/*.t t/*.pl; do + perl -i -MConfig -ple 'print $Config{startperl} if $. == 1 && !s{\A#!.*perl\b}{$Config{startperl}}' "$F" + chmod +x "$F" +done + %build export GNUPGHOME=%{gnupghome} perl Makefile.PL INSTALLDIRS=vendor --skipdeps %{buildroot}/%{_libexecdir}/%{name}/test << 'EOF' +#!/bin/bash +set -e +# Some tests write into temporary files/directories. The easiest solution +# is to copy the tests into a writable directory and execute them from there. +DIR=$(mktemp -d) +pushd "$DIR" +cp -a %{_libexecdir}/%{name}/* ./ +prove -I . -j "$(getconf _NPROCESSORS_ONLN)" +popd +rm -rf "$DIR" +EOF +chmod +x %{buildroot}/%{_libexecdir}/%{name}/test + %check export GNUPGHOME=%{gnupghome} make test -%clean -rm -rf %{buildroot} %{gnupghome} - %files %doc AUTHORS Changes README *.pub %{_bindir}/cpansign @@ -89,7 +120,23 @@ rm -rf %{buildroot} %{gnupghome} %{_mandir}/man1/cpansign.1* %{_mandir}/man3/Module::Signature.3* +%files tests +%{_libexecdir}/%{name} + %changelog +* Sat Dec 18 2021 Paul Howarth - 0.88-1 +- Update to 0.88 + - Update PAUSE keys to 2022 + +* Thu Jul 22 2021 Fedora Release Engineering - 0.87-5 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild + +* Fri May 21 2021 Jitka Plesnikova - 0.87-4 +- Perl 5.34 rebuild + +* Wed Jan 27 2021 Fedora Release Engineering - 0.87-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild + * Tue Jul 28 2020 Fedora Release Engineering - 0.87-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild diff --git a/plans/sanity.fmf b/plans/sanity.fmf new file mode 100644 index 0000000..a72ded4 --- /dev/null +++ b/plans/sanity.fmf @@ -0,0 +1,5 @@ +summary: Sanity tests +discover: + how: fmf +execute: + how: tmt diff --git a/sources b/sources index 53e3ec1..178c3ac 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (Module-Signature-0.87.tar.gz) = d0afeab528d0b8a46b8a6a1f9714ab7efefb386f5b93113e733fa18b23b38c98c6a13f10e9091c0cbf392956cd02484d09482d31cd9146ed6de11adb7cd81124 +SHA512 (Module-Signature-0.88.tar.gz) = 624d7508b7854e05c50915b9192552fddd17e22043f2b330c02c34ad44dd01cb0ffd657fcd4e5333324b2ce9a05e044772e80c3ae061608f91d8101d00b3666c diff --git a/tests/upstream-tests.fmf b/tests/upstream-tests.fmf new file mode 100644 index 0000000..ea620f7 --- /dev/null +++ b/tests/upstream-tests.fmf @@ -0,0 +1,4 @@ +summary: Upstream tests +component: perl-Module-Signature +require: perl-Module-Signature-tests +test: /usr/libexec/perl-Module-Signature/test