From d56bd7eab9c080b8552798be6b864d1f2a0b79e0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C5=A0t=C4=9Bp=C3=A1n=20Hor=C3=A1=C4=8Dek?= Date: Thu, 24 Feb 2022 18:27:31 +0100 Subject: [PATCH] Use tests from build MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Previously the tests were cloned from the upstream repo, where they also contain tests for SHA-1. After restricting SHA-1, these tests cannot succeed. Use updated tests from patches instead. Resolves: rhbz#2060768 Signed-off-by: Štěpán Horáček --- tests/runtest.sh | 11 +++-------- tests/tests.yml | 3 +++ tss2.spec | 3 ++- 3 files changed, 8 insertions(+), 9 deletions(-) diff --git a/tests/runtest.sh b/tests/runtest.sh index 51b8d02..c5995b4 100755 --- a/tests/runtest.sh +++ b/tests/runtest.sh @@ -39,12 +39,8 @@ sleep 10 export TPM_INTERFACE_TYPE=socsim -# get tss2 tests -TSS2_VERSION=v1.6.0 -git clone https://git.code.sf.net/p/ibmtpm20tss/tss -pushd tss -git checkout -b test $TSS2_VERSION -pushd utils +# use the tss2 tests from the sources +pushd ./source/utils # fix python calls to use rhel name for python3 sed -i -e 's/^PREFIX=\.\//PREFIX=tss/g' reg.sh # fix paths in rootcerts.txt @@ -54,10 +50,9 @@ sed -i -e "s|/gsa/yktgsa/home/k/g/kgold/tpm2/utils|${c}|g" certificates/rootcert ./reg.sh -a res="$?" popd -popd # clean up pkill tpm_server -rm -rf ibmtpm ibmtpm$IBMTPM_VERSION.tar.gz tss +rm -rf ibmtpm tss exit $res diff --git a/tests/tests.yml b/tests/tests.yml index 61285b2..b945566 100644 --- a/tests/tests.yml +++ b/tests/tests.yml @@ -1,5 +1,8 @@ - hosts: localhost roles: + - role: standard-test-source + tags: + - always - role: standard-test-basic tags: - classic diff --git a/tss2.spec b/tss2.spec index 4e95853..f290d18 100644 --- a/tss2.spec +++ b/tss2.spec @@ -28,6 +28,7 @@ BuildRequires: autoconf BuildRequires: libtool BuildRequires: gcc BuildRequires: openssl-devel +BuildRequires: git Requires: openssl %description @@ -48,7 +49,7 @@ Development libraries and headers for IBM's TSS 2.0. You will need this in order to build TSS 2.0 applications. %prep -%autosetup -p1 -c %{name}-%{version} +%autosetup -S git -p1 -c %{name}-%{version} %build autoreconf -vi