Skip to content

Commit 2098453

Browse files
authored
fix: fix flaky test in kafkatopicsobserver (#38218)
#### Description Fixing a flaky test #### Link to tracking issue Fixes #38192
1 parent 47ff222 commit 2098453

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

extension/observer/kafkatopicsobserver/extension_test.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -105,11 +105,11 @@ func TestCollectEndpointsAllConfigSettings(t *testing.T) {
105105
Details: &observer.KafkaTopic{},
106106
},
107107
}
108-
require.Equal(t, want, kEndpoints)
108+
require.ElementsMatch(t, want, kEndpoints)
109109

110110
time.Sleep(5 * time.Second)
111111
kEndpoints = obvs.ListEndpoints()
112-
require.Equal(t, want, kEndpoints)
112+
require.ElementsMatch(t, want, kEndpoints)
113113

114114
time.Sleep(5 * time.Second)
115115
kEndpoints = obvs.ListEndpoints()
@@ -120,7 +120,7 @@ func TestCollectEndpointsAllConfigSettings(t *testing.T) {
120120
Details: &observer.KafkaTopic{},
121121
},
122122
}
123-
require.Equal(t, want, kEndpoints)
123+
require.ElementsMatch(t, want, kEndpoints)
124124

125125
err = obvs.Shutdown(context.Background())
126126
require.NoError(t, err)

0 commit comments

Comments
 (0)