tests: add check_skip_kernel_test to check root user and lttng kernel modules
[lttng-tools.git] / tests / regression / kernel / test_syscall
index f9b49085835b39b2fc109b53b8ff61998e0710ed..92d79a7bcba884e28995ac75dfd6740a5f79dd7d 100755 (executable)
@@ -664,13 +664,7 @@ plan_tests $NUM_TESTS
 
 print_test_banner "$TEST_DESC"
 
-if [ "$(id -u)" == "0" ]; then
-       isroot=1
-else
-       isroot=0
-fi
-
-skip $isroot "Root access is needed. Skipping all tests." $NUM_TESTS ||
+check_skip_kernel_test "$NUM_TESTS" "Skipping all tests." ||
 {
        validate_lttng_modules_present
        start_lttng_sessiond
This page took 0.0237 seconds and 4 git commands to generate.