We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 544bbbc commit 823c419Copy full SHA for 823c419
1 file changed
tests/test_audio_stream_track.py
@@ -360,6 +360,12 @@ async def test_buffer_overflow_does_not_reallocate(self):
360
assert track._buffer is buffer_ref, (
361
"overflow trim should modify buffer in-place, not create a new one"
362
)
363
+ max_buffer_seconds = 100 / 1000
364
+ bytes_per_sample = 2
365
+ expected_max_bytes = int(max_buffer_seconds * 48000) * bytes_per_sample
366
+ assert len(track._buffer) == expected_max_bytes, (
367
+ "buffer should be trimmed to configured max size"
368
+ )
369
370
@pytest.mark.asyncio
371
async def test_media_stream_error(self):
0 commit comments