From 120ca1bb7c91cc186fd0f149f6118a501af28716 Mon Sep 17 00:00:00 2001 From: Alexander Bokovoy Date: Thu, 8 Feb 2024 11:19:13 +0200 Subject: [PATCH] Fix FTBS by running p11 tests individually The tests in src/lib/test ran through p11test driver. When CPPUNIT runs them, the order is not guaranteed and tests fail differently each run. When individual test suites being run as `p11test TestName`, they all succeed. Switch test runs to explicit order. Related: RHEL-24824 Signed-off-by: Alexander Bokovoy --- softhsm.spec | 20 ++++++++++++++++++-- 1 file changed, 18 insertions(+), 2 deletions(-) diff --git a/softhsm.spec b/softhsm.spec index 24dbe7b..32588e9 100644 --- a/softhsm.spec +++ b/softhsm.spec @@ -4,7 +4,7 @@ Summary: Software version of a PKCS#11 Hardware Security Module Name: softhsm Version: 2.6.1 -Release: %{?prever:0.}7%{?prever:.%{prever}}%{?dist}.2 +Release: %{?prever:0.}8%{?prever:.%{prever}}%{?dist} License: BSD Url: http://www.opendnssec.org/ Source: http://dist.opendnssec.org/source/%{?prever:testing/}%{name}-%{version}.tar.gz @@ -70,7 +70,19 @@ autoreconf -fiv %make_build %check -make check +for d in crypto data_mgr handle_mgr object_store session_mgr slot_mgr ; do +make check -C src/lib/$d +done + +pushd src/lib/test +make p11test +for t in TokenTests AsymWrapUnwrapTests DigestTests ForkTests \ + InitTests InfoTests SessionTests UserTests RandomTests \ + SignVerifyTests AsymEncryptDecryptTests DeriveTests \ + ObjectTests SymmetricAlgorithmTests ; do +./p11test $t +done +popd %install rm -rf %{buildroot} @@ -121,6 +133,10 @@ if [ -f /var/softhsm/slot0.db ]; then fi %changelog +* Thu Feb 08 2024 Alexander Bokovoy - 2.6.1-8 +- Run p11test tests individually +- Resolves: rhbz#2261703 + * Tue Aug 10 2021 Mohan Boddu - 2.6.1-7.2 - Rebuilt for IMA sigs, glibc 2.34, aarch64 flags Related: rhbz#1991688