From dbf8fbea5810fc22af60edce687af34953054a60 Mon Sep 17 00:00:00 2001 From: x12sa Date: Tue, 29 Sep 2026 12:56:07 +0200 Subject: [PATCH] fix(tests): give leye_out shutter test a csaxs and client stub leye_out() now reads self.csaxs and self.client (slit/filter handling), which the bare LamNIOpticsMixin subclass in the test did not define. Co-Authored-By: Claude Sonnet 5.5 --- .../tests_bec_ipython_client/test_lamni_golive_fixes.py | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/tests/tests_bec_ipython_client/test_lamni_golive_fixes.py b/tests/tests_bec_ipython_client/test_lamni_golive_fixes.py index 588b1381..44c5064e 100644 --- a/tests/tests_bec_ipython_client/test_lamni_golive_fixes.py +++ b/tests/tests_bec_ipython_client/test_lamni_golive_fixes.py @@ -187,7 +187,16 @@ def test_leye_out_closes_the_fast_shutter(monkeypatch): monkeypatch.setattr(optics_mixin_module, "dev", FakeDev(), raising=False) monkeypatch.setattr(optics_mixin_module, "umv", lambda *a: None, raising=False) + class FakeClient: + # no slit position stored before the eye went in -> nothing to restore + @staticmethod + def get_global_var(name): + return None + class Optics(LamNIOpticsMixin): + csaxs = None + client = FakeClient() + def loptics_in(self): pass