From 0c1d041ce5d7fcc8a4986e259b59f09945c097ba Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Geyslan=20Greg=C3=B3rio?= Date: Wed, 25 Sep 2024 12:02:29 -0300 Subject: [PATCH] fix(tests): use ExpectAtLeastOneForEach Two test cases were using ExpectAllInOrderSequentially helper function and passing by luck, since they emit more events than expected only beyond the expected events boundary. For that cases we should use ExpectAtLeastOneForEach helper function instead. --- tests/integration/event_filters_test.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/integration/event_filters_test.go b/tests/integration/event_filters_test.go index bf2c50095740..2727423f6f2a 100644 --- a/tests/integration/event_filters_test.go +++ b/tests/integration/event_filters_test.go @@ -771,7 +771,7 @@ func Test_EventFilters(t *testing.T) { }, useSyscaller: false, coolDown: 0, - test: ExpectAllInOrderSequentially, + test: ExpectAtLeastOneForEach, }, { name: "pid: trace new (should be empty)", @@ -1504,7 +1504,7 @@ func Test_EventFilters(t *testing.T) { }, useSyscaller: true, coolDown: 0, - test: ExpectAllInOrderSequentially, + test: ExpectAtLeastOneForEach, // syscaller might emit its own events, so we expect at least one of each }, { name: "event: trace execve event set in a specific policy from fakeprog1 command",