Fix tests now background status settings are returned as dictionaries.
This commit is contained in:
parent
33413a591a
commit
5296092b6b
2 changed files with 3 additions and 2 deletions
|
|
@ -23,6 +23,6 @@ class MockCameraThing:
|
|||
|
||||
background_detector_status = BackgroundDetectorStatus(
|
||||
ready=True,
|
||||
settings=ColourChannelDetectSettings(),
|
||||
settings=ColourChannelDetectSettings().model_dump(),
|
||||
settings_schema={"fake": "schema"},
|
||||
)
|
||||
|
|
|
|||
|
|
@ -70,7 +70,8 @@ def test_partial_base_class(background_image):
|
|||
bad_algo1 = BadAlgo1()
|
||||
status = bad_algo1.status
|
||||
assert not status.ready
|
||||
assert isinstance(status.settings, ColourChannelDetectSettings)
|
||||
# Check the settings dictionary can be validated as ``ColourChannelDetectSettings``
|
||||
ColourChannelDetectSettings(**status.settings)
|
||||
|
||||
with pytest.raises(NotImplementedError):
|
||||
# Should error on any dictionary input. This simulates loading settings from
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue