tests: add check_skip_kernel_test to check root user and lttng kernel modules
[lttng-tools.git] / tests / regression / tools / snapshots / test_kernel
index 870c437b217fc2ed0eb339628fff428e220312fd..302e5b341c0b800059a5c84750ead2de5b962714 100755 (executable)
@@ -221,14 +221,7 @@ print_test_banner "$TEST_DESC"
 
 bail_out_if_no_babeltrace
 
-
-if [ "$(id -u)" == "0" ]; then
-       isroot=1
-else
-       isroot=0
-fi
-
-skip $isroot "Root access is needed. Skipping all kernel snapshot tests" $NUM_TESTS ||
+check_skip_kernel_test "$NUM_TESTS" "Skipping all tests." ||
 {
 
        validate_lttng_modules_present
This page took 0.027461 seconds and 4 git commands to generate.