Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
35 changes: 31 additions & 4 deletions .github/workflows/alpine-architecture-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,9 @@ jobs:
musl-dev
openssl-dev
bash
gcc
gdb
valgrind
shell-name: alpine.sh

- name: Cache wolfSSL
Expand Down Expand Up @@ -139,7 +142,7 @@ jobs:
echo "Running autogen.sh..."
./autogen.sh
echo "Running configure..."
./configure
./configure LDFLAGS="-Wl,-z,stack-size=1048576" CFLAGS="-g -O0 -fno-omit-frame-pointer"
make
shell: alpine.sh {0}

Expand All @@ -152,7 +155,7 @@ jobs:
echo "Running autogen.sh..."
./autogen.sh
echo "Running configure..."
./configure --enable-singlethreaded --enable-wolftpm --disable-dh C_EXTRA_FLAGS="-DWOLFPKCS11_TPM_STORE"
./configure --enable-singlethreaded --enable-wolftpm --disable-dh C_EXTRA_FLAGS="-DWOLFPKCS11_TPM_STORE" LDFLAGS="-Wl,-z,stack-size=1048576" CFLAGS="-g -O0 -fno-omit-frame-pointer"
make
shell: alpine.sh {0}

Expand All @@ -161,15 +164,39 @@ jobs:
run: |
echo "=== Running tests without TPM on ${{ matrix.arch }} ==="
export LD_LIBRARY_PATH="/usr/local/lib:$LD_LIBRARY_PATH"
make test
# Run the test multiple times to catch intermittent failures
for i in {1..5}; do
echo "=== Test run $i ==="
if ! make test; then
echo "Test failed on run $i"
# Show any available logs
find . -name "*.log" -exec echo "=== {} ===" \; -exec cat {} \;
echo "=== Core dumps ==="
find . -name "core*" -exec ls -la {} \;
exit 1
fi
echo "Test run $i completed successfully"
done
shell: alpine.sh {0}

- name: Run tests (with TPM)
if: matrix.tpm == 'with-tpm'
run: |
echo "=== Running TPM tests on ${{ matrix.arch }} ==="
export LD_LIBRARY_PATH="/usr/local/lib:$LD_LIBRARY_PATH"
./tests/pkcs11str && ./tests/pkcs11test && ./tests/rsa_session_persistence_test
# Run the tests multiple times to catch intermittent failures
for i in {1..5}; do
echo "=== TPM test run $i ==="
if ! (./tests/pkcs11str && ./tests/pkcs11test && ./tests/rsa_session_persistence_test); then
echo "TPM tests failed on run $i"
# Show any available logs
find . -name "*.log" -exec echo "=== {} ===" \; -exec cat {} \;
echo "=== Core dumps ==="
find . -name "core*" -exec ls -la {} \;
exit 1
fi
echo "TPM test run $i completed successfully"
done
shell: alpine.sh {0}

- name: Cleanup TPM server
Expand Down
Loading