Skip to content

Commit 59ed076

Browse files
committed
Align tests with writer options override rename
Update test fixtures and GUI recorder-manager assertions to use `writer_options_overrides` instead of `writer_options`. This keeps the fake recorder interface consistent with the current recorder API and ensures writegear option checks target the renamed field.
1 parent 6e3a7cd commit 59ed076

2 files changed

Lines changed: 8 additions & 7 deletions

File tree

‎tests/conftest.py‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -358,7 +358,7 @@ def __init__(
358358
crf=23,
359359
buffer_size=240,
360360
convert_grayscale_to_rgb=True,
361-
writer_options=None,
361+
writer_options_overrides=None,
362362
**kwargs,
363363
):
364364
self.output = Path(output)
@@ -368,7 +368,7 @@ def __init__(
368368
self.crf = crf
369369
self.buffer_size = buffer_size
370370
self.convert_grayscale_to_rgb = convert_grayscale_to_rgb
371-
self.writer_options = dict(writer_options) if writer_options is not None else None
371+
self.writer_options_overrides = dict(writer_options_overrides) if writer_options_overrides is not None else None
372372
self.extra_kwargs = dict(kwargs)
373373

374374
self.started = False

‎tests/gui/test_rec_manager.py‎

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -417,8 +417,9 @@ def test_start_all_passes_writegear_options(
417417
cam_id = get_camera_id(cam)
418418
rec = mgr.recorders[cam_id]
419419

420-
assert rec.writer_options is not None
421-
assert rec.writer_options["-vcodec"] == "libx264"
422-
assert rec.writer_options["-crf"] == "23"
423-
assert rec.writer_options["-preset"] == "ultrafast"
424-
assert rec.writer_options["-tune"] == "zerolatency"
420+
opts_ovrr = rec.writer_options_overrides
421+
assert opts_ovrr is not None
422+
assert opts_ovrr["-vcodec"] == "libx264"
423+
assert opts_ovrr["-crf"] == "23"
424+
assert opts_ovrr["-preset"] == "ultrafast"
425+
assert opts_ovrr["-tune"] == "zerolatency"

0 commit comments

Comments
 (0)