From 17b326775bd251c2e5befc9af3233b6a77c828b1 Mon Sep 17 00:00:00 2001 From: William Roberts Date: Thu, 11 Feb 2021 14:53:18 -0600 Subject: [PATCH] ci: run tpm2-tools test suite To ensure changes in the tpm2-tss don't break dependent projects, run the tpm2-tools test suite as part of the CI. This also builds tpm2-abrmd since the tpm2-tools test suite is dependent on that project. Signed-off-by: William Roberts --- .ci/docker.run | 28 +++++++++++++++++++++++++--- 1 file changed, 25 insertions(+), 3 deletions(-) diff --git a/.ci/docker.run b/.ci/docker.run index f898f57f3..5a7b256f0 100755 --- a/.ci/docker.run +++ b/.ci/docker.run @@ -83,8 +83,6 @@ else make -j check fi -popd - else # TEST_TCTI_CONFIG == true mkdir ./config_test pushd ./config_test @@ -121,9 +119,33 @@ if [ "$CC" == "gcc" ]; then ../configure --disable-doxygen-doc --enable-unit --enable-integration --enable-tcti-swtpm --enable-tcti-mssim --enable-tcti-device make -j check TESTS="test/unit/tcti-swtpm test/unit/tcti-mssim test/unit/tcti-device" fi # CC == gcc -popd fi # TEST_TCTI_CONFIG +# Test that we don't break the tools by: +# - running install before leaving the build variant directory +# - returning to the top level tpm2-tss folder and git cloning: +# - tpm2-abrmd +# - tpm2-tools +# - Building all projects +# - Runing the tools test suite +make install +popd + +git clone --depth=1 https://github.com/tpm2-software/tpm2-abrmd.git +pushd tpm2-abrmd +./bootstrap +./configure CFLAGS=-g +make -j$(nproc) +make install +popd + +git clone --depth=1 https://github.com/tpm2-software/tpm2-tools.git +pushd tpm2-tools +./bootstrap +./configure --enable-unit --enable-integration +make -j$(nproc) check +popd + # back in root git directory, check for whitespace errors. We do this post CI # so people can verify the rest of their patch works in CI before dying. # git diff --check fails with a non-zero return code causing the shell to die