Test for the presence of the tracepoint_test file before running the test
[ust.git] / tests / tracepoint / run
index 0da98641ccd4bbcdc0f8ef840c2e171fc8f6bd39..d63f42de89841b9bb386da10b280e02f58452784 100755 (executable)
@@ -2,14 +2,20 @@
 
 TESTDIR=$(dirname $0)/..
 
+if [ ! -x "$TESTDIR/tracepoint/tracepoint_test" ]; then
+    echo "tracepoint_test executable is not present"
+    exit 1
+fi
+
 source $TESTDIR/test_functions.sh
 source $TESTDIR/tap.sh
 
 starttest "Testing Tracepoints"
 plan_tests 6
+USTTRACE="$TESTDIR/../usttrace"
 
-okx usttrace $TESTDIR/tracepoint/tracepoint_test
-trace_loc=$(usttrace -W)
+okx $USTTRACE -L $TESTDIR/tracepoint/tracepoint_test
+trace_loc=$($USTTRACE -W)
 trace_matches -N "probe1" -n "5" "probe = 13" $trace_loc
 trace_matches -N "probe2" -n "5" "probe = 42" $trace_loc
 trace_matches -N "probe3" -n "1" "probe = \"probe3\"" $trace_loc
This page took 0.023307 seconds and 4 git commands to generate.