summaryrefslogtreecommitdiff
path: root/tests/debuginfod-subr.sh
diff options
context:
space:
mode:
Diffstat (limited to 'tests/debuginfod-subr.sh')
-rwxr-xr-xtests/debuginfod-subr.sh10
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/debuginfod-subr.sh b/tests/debuginfod-subr.sh
index 59033f35..0b59b5b8 100755
--- a/tests/debuginfod-subr.sh
+++ b/tests/debuginfod-subr.sh
@@ -158,3 +158,13 @@ PORT1=0
PORT2=0
PID1=0
PID2=0
+
+
+# run $1 as a sh -c command, invert result code
+xfail() {
+ if sh -c "$1"; then
+ false
+ else
+ true
+ fi
+}