chore: shut down plugins gracefully to prevent race (#12102)

This commit is contained in:
reimda 2022-10-26 09:32:58 -06:00 committed by GitHub
parent 9d9eb403a6
commit 3196bc4c1c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 2 deletions

View File

@ -470,8 +470,6 @@ func TestConsumerGroupHandler_Handle(t *testing.T) {
}
func TestKafkaRoundTripIntegration(t *testing.T) {
t.Skip("fails race check")
if testing.Short() {
t.Skip("Skipping integration test in short mode")
}
@ -574,5 +572,9 @@ func TestKafkaRoundTripIntegration(t *testing.T) {
acc.Wait(len(expected))
testutil.RequireMetricsEqual(t, expected, acc.GetTelegrafMetrics())
t.Logf("rt: shutdown")
require.NoError(t, output.Close())
input.Stop()
t.Logf("rt: done")
}