diff --git a/internal/core/metrics_test.go b/internal/core/metrics_test.go index c84da72f..245bc0bd 100644 --- a/internal/core/metrics_test.go +++ b/internal/core/metrics_test.go @@ -7,6 +7,7 @@ import ( "net/url" "os" "testing" + "time" "github.com/bluenviron/gortsplib/v3" "github.com/bluenviron/gortsplib/v3/pkg/formats" @@ -103,6 +104,8 @@ webrtc_sessions_bytes_sent 0 err = conn.WriteTracks(videoTrack, nil) require.NoError(t, err) + time.Sleep(500 * time.Millisecond) + bo = httpPullFile(t, hc, "http://localhost:9998/metrics") require.Regexp(t,