Fix blocking I/O in stream tests (#121142)

This commit is contained in:
J. Nick Koston 2024-07-03 23:15:26 -05:00 committed by GitHub
parent 7002042119
commit a4d4fc6827
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -305,7 +305,5 @@ async def test_record_stream_rotate(hass: HomeAssistant, filename, h264_video) -
# Assert
assert os.path.exists(filename)
with open(filename, "rb") as rotated_mp4:
assert_mp4_has_transform_matrix(
rotated_mp4.read(), stream.dynamic_stream_settings.orientation
)
data = await hass.async_add_executor_job(Path(filename).read_bytes)
assert_mp4_has_transform_matrix(data, stream.dynamic_stream_settings.orientation)