From 8a24692e822cfe7bd6fa22f2d44183d1629a0dcf Mon Sep 17 00:00:00 2001 From: wakonig_k Date: Tue, 14 May 2024 14:08:19 +0200 Subject: [PATCH] fix: fixed import after refactoring --- .../device_configs/e21125_lamni_config.yaml | 16 ++++++++-------- csaxs_bec/devices/galil/__init__.py | 2 +- tests/tests_devices/test_galil.py | 10 +++++----- tests/tests_devices/test_galil_flomni.py | 2 -- 4 files changed, 14 insertions(+), 16 deletions(-) diff --git a/csaxs_bec/device_configs/e21125_lamni_config.yaml b/csaxs_bec/device_configs/e21125_lamni_config.yaml index feb5868..9f9435b 100644 --- a/csaxs_bec/device_configs/e21125_lamni_config.yaml +++ b/csaxs_bec/device_configs/e21125_lamni_config.yaml @@ -3,7 +3,7 @@ ############################################################ leyex: description: phase plate angle - deviceClass: csaxs_bec.devices.galil.galil_ophyd.GalilMotor + deviceClass: csaxs_bec.devices.galil.lgalil_ophyd.LamniGalilMotor deviceConfig: axis_Id: G host: mpc2680.psi.ch @@ -22,7 +22,7 @@ leyex: in: 14.117 leyey: description: phase plate angle - deviceClass: csaxs_bec.devices.galil.galil_ophyd.GalilMotor + deviceClass: csaxs_bec.devices.galil.lgalil_ophyd.LamniGalilMotor deviceConfig: axis_Id: H host: mpc2680.psi.ch @@ -42,7 +42,7 @@ leyey: out: 0.5 loptx: description: phase plate angle - deviceClass: csaxs_bec.devices.galil.galil_ophyd.GalilMotor + deviceClass: csaxs_bec.devices.galil.lgalil_ophyd.LamniGalilMotor deviceConfig: axis_Id: E host: mpc2680.psi.ch @@ -62,7 +62,7 @@ loptx: out: -0.699 lopty: description: phase plate angle - deviceClass: csaxs_bec.devices.galil.galil_ophyd.GalilMotor + deviceClass: csaxs_bec.devices.galil.lgalil_ophyd.LamniGalilMotor deviceConfig: axis_Id: F host: mpc2680.psi.ch @@ -82,7 +82,7 @@ lopty: out: 3.53 loptz: description: phase plate angle - deviceClass: csaxs_bec.devices.galil.galil_ophyd.GalilMotor + deviceClass: csaxs_bec.devices.galil.lgalil_ophyd.LamniGalilMotor deviceConfig: axis_Id: D host: mpc2680.psi.ch @@ -99,7 +99,7 @@ loptz: readoutPriority: baseline lsamrot: description: phase plate angle - deviceClass: csaxs_bec.devices.galil.galil_ophyd.GalilMotor + deviceClass: csaxs_bec.devices.galil.lgalil_ophyd.LamniGalilMotor deviceConfig: axis_Id: C host: mpc2680.psi.ch @@ -116,7 +116,7 @@ lsamrot: readoutPriority: baseline lsamx: description: phase plate angle - deviceClass: csaxs_bec.devices.galil.galil_ophyd.GalilMotor + deviceClass: csaxs_bec.devices.galil.lgalil_ophyd.LamniGalilMotor deviceConfig: axis_Id: A host: mpc2680.psi.ch @@ -135,7 +135,7 @@ lsamx: center: 8.768 lsamy: description: phase plate angle - deviceClass: csaxs_bec.devices.galil.galil_ophyd.GalilMotor + deviceClass: csaxs_bec.devices.galil.lgalil_ophyd.LamniGalilMotor deviceConfig: axis_Id: B host: mpc2680.psi.ch diff --git a/csaxs_bec/devices/galil/__init__.py b/csaxs_bec/devices/galil/__init__.py index 0ad6966..5ec9eb2 100644 --- a/csaxs_bec/devices/galil/__init__.py +++ b/csaxs_bec/devices/galil/__init__.py @@ -1,4 +1,4 @@ from .fgalil_ophyd import FlomniGalilController, FlomniGalilMotor from .fupr_ophyd import FuprGalilController, FuprGalilMotor -from .galil_ophyd import GalilController, GalilMotor +from .lgalil_ophyd import LamniGalilController, LamniGalilMotor from .sgalil_ophyd import SGalilMotor diff --git a/tests/tests_devices/test_galil.py b/tests/tests_devices/test_galil.py index 0e73ea1..8675d66 100644 --- a/tests/tests_devices/test_galil.py +++ b/tests/tests_devices/test_galil.py @@ -3,13 +3,13 @@ from unittest import mock import pytest from ophyd_devices.tests.utils import SocketMock -from csaxs_bec.devices.galil.galil_ophyd import GalilController, GalilMotor +from csaxs_bec.devices.galil.lgalil_ophyd import LamniGalilController, LamniGalilMotor @pytest.fixture(scope="function") def leyey(): - GalilController._reset_controller() - leyey_motor = GalilMotor( + LamniGalilController._reset_controller() + leyey_motor = LamniGalilMotor( "H", name="leyey", host="mpc2680.psi.ch", port=8081, socket_cls=SocketMock ) leyey_motor.controller.on() @@ -20,8 +20,8 @@ def leyey(): @pytest.fixture(scope="function") def leyex(): - GalilController._reset_controller() - leyex_motor = GalilMotor( + LamniGalilController._reset_controller() + leyex_motor = LamniGalilMotor( "A", name="leyey", host="mpc2680.psi.ch", port=8081, socket_cls=SocketMock ) leyex_motor.controller.on() diff --git a/tests/tests_devices/test_galil_flomni.py b/tests/tests_devices/test_galil_flomni.py index 3450d29..790b987 100644 --- a/tests/tests_devices/test_galil_flomni.py +++ b/tests/tests_devices/test_galil_flomni.py @@ -1,5 +1,3 @@ -from unittest import mock - import pytest from ophyd_devices.tests.utils import SocketMock