Cleanup: tests: name all temporary files to better identify leakage
[lttng-tools.git] / tests / regression / tools / trigger / test_list_triggers_cli
index cb7a3b4760d68f0c0da14c27ba2890a685228314..26f2f9f46e4b53d0167f478485df57431bf75508 100755 (executable)
@@ -27,9 +27,9 @@ NUM_TESTS=106
 
 FULL_LTTNG_BIN="${TESTDIR}/../src/bin/lttng/${LTTNG_BIN}"
 
-tmp_stdout=$(mktemp -t test_list_triggers_cli_stdout.XXXXXX)
-tmp_stderr=$(mktemp -t test_list_triggers_cli_stderr.XXXXXX)
-tmp_expected_stdout=$(mktemp -t test_list_triggers_cli_expected_stdout.XXXXXX)
+tmp_stdout=$(mktemp --tmpdir -t test_list_triggers_cli_stdout.XXXXXX)
+tmp_stderr=$(mktemp --tmpdir -t test_list_triggers_cli_stderr.XXXXXX)
+tmp_expected_stdout=$(mktemp --tmpdir -t test_list_triggers_cli_expected_stdout.XXXXXX)
 uprobe_elf_binary=$(realpath "${TESTDIR}/utils/testapp/userspace-probe-elf-binary/.libs/userspace-probe-elf-binary")
 uprobe_sdt_binary=$(realpath "${TESTDIR}/utils/testapp/userspace-probe-sdt-binary/.libs/userspace-probe-sdt-binary")
 register_some_triggers_bin=$(realpath "${CURDIR}/utils/register-some-triggers")
@@ -51,21 +51,6 @@ else
 fi
 
 
-function list_triggers_matches_ok ()
-{
-       local test_name="$1"
-       local expected_stdout_file="$2"
-
-       "${FULL_LTTNG_BIN}" list-triggers > "${tmp_stdout}" 2> "${tmp_stderr}"
-       ok $? "${test_name}: exit code is 0"
-
-       diff -u "${expected_stdout_file}" "${tmp_stdout}"
-       ok $? "${test_name}: expected stdout"
-
-       diff -u /dev/null "${tmp_stderr}"
-       ok $? "${test_name}: expected stderr"
-}
-
 test_top_level_options ()
 {
        diag "Listing top level options"
@@ -575,7 +560,7 @@ test_snapshot_action ()
          condition: event rule matches
            rule: some-event (type: tracepoint, domain: ust)
          actions:
-           snapshot session \`ze-session\`, rate policy: after every 10 occurrences
+           snapshot session \`ze-session\`, rate policy: every 10 occurrences
              errors: none
          errors: none
        - name: T9
@@ -621,7 +606,7 @@ test_notify_action ()
          condition: event rule matches
            rule: some-event (type: tracepoint, domain: ust)
          actions:
-           notify, rate policy: after every 10 occurrences
+           notify, rate policy: every 10 occurrences
              errors: none
          errors: none
        EOF
This page took 0.024176 seconds and 4 git commands to generate.