+test_notify_action ()
+{
+ start_lttng_sessiond_notap
+
+ lttng_add_trigger_ok "T0" --condition on-event -u some-event --action notify --rate-policy=once-after:5
+ lttng_add_trigger_ok "T1" --condition on-event -u some-event --action notify --rate-policy=every:10
+
+
+ cat > "${tmp_expected_stdout}" <<- EOF
+ - name: T0
+ user id: ${uid}
+ condition: event rule hit
+ rule: some-event (type: tracepoint, domain: ust)
+ actions:
+ notify, rate policy: once after 5 occurrences
+ errors: none
+ errors: none
+ - name: T1
+ user id: ${uid}
+ condition: event rule hit
+ rule: some-event (type: tracepoint, domain: ust)
+ actions:
+ notify, rate policy: after every 10 occurrences
+ errors: none
+ errors: none
+ EOF
+
+ list_triggers_matches_ok "snapshot action" "${tmp_expected_stdout}"
+
+ lttng_remove_trigger_ok "T0"
+ lttng_remove_trigger_ok "T1"
+}
+
+plan_tests $NUM_TESTS
+
+# shellcheck disable=SC2119
+start_lttng_sessiond_notap
+