summaryrefslogtreecommitdiff
path: root/tools/testing/selftests/tpm2/test_space.sh
diff options
context:
space:
mode:
Diffstat (limited to 'tools/testing/selftests/tpm2/test_space.sh')
-rwxr-xr-xtools/testing/selftests/tpm2/test_space.sh9
1 files changed, 8 insertions, 1 deletions
diff --git a/tools/testing/selftests/tpm2/test_space.sh b/tools/testing/selftests/tpm2/test_space.sh
index a6f5e346635e..180b469c53b4 100755
--- a/tools/testing/selftests/tpm2/test_space.sh
+++ b/tools/testing/selftests/tpm2/test_space.sh
@@ -1,4 +1,11 @@
#!/bin/bash
# SPDX-License-Identifier: (GPL-2.0 OR BSD-3-Clause)
-python -m unittest -v tpm2_tests.SpaceTest
+# Kselftest framework requirement - SKIP code is 4.
+ksft_skip=4
+
+if [ -f /dev/tpmrm0 ] ; then
+ python -m unittest -v tpm2_tests.SpaceTest
+else
+ exit $ksft_skip
+fi