Skip to content

Commit a49ed79

Browse files
committed
fix motor limits test, fix deprecationwarnings for ophyd_async.testing imports
1 parent da57404 commit a49ed79

File tree

11 files changed

+13
-13
lines changed

11 files changed

+13
-13
lines changed

tests/devices/simpledae/test_controllers.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import pytest
2-
from ophyd_async.testing import get_mock_put, set_mock_value
2+
from ophyd_async.core import get_mock_put, set_mock_value
33

44
from ibex_bluesky_core.devices.dae import BeginRunExBits, RunstateEnum
55
from ibex_bluesky_core.devices.simpledae import (

tests/devices/simpledae/test_reducers.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
import numpy as np
77
import pytest
88
import scipp as sc
9-
from ophyd_async.testing import get_mock_put, set_mock_value
9+
from ophyd_async.core import get_mock_put, set_mock_value
1010

1111
from ibex_bluesky_core.devices.simpledae import (
1212
VARIANCE_ADDITION,

tests/devices/simpledae/test_simpledae.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
11
from unittest.mock import AsyncMock, MagicMock, patch
22

33
import pytest
4-
from ophyd_async.core import Device, StandardReadable, soft_signal_rw
5-
from ophyd_async.testing import set_mock_value
4+
from ophyd_async.core import Device, StandardReadable, set_mock_value, soft_signal_rw
65

76
from ibex_bluesky_core.devices.dae import Dae, DaeCheckingSignal
87
from ibex_bluesky_core.devices.simpledae import (

tests/devices/simpledae/test_waiters.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import asyncio
22

33
import pytest
4-
from ophyd_async.testing import set_mock_value
4+
from ophyd_async.core import set_mock_value
55

66
from ibex_bluesky_core.devices.simpledae import (
77
GoodUahWaiter,

tests/devices/test_block.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
import bluesky.plans as bp
77
import ophyd_async
88
import pytest
9-
from ophyd_async.testing import get_mock_put, set_mock_value
9+
from ophyd_async.core import get_mock_put, set_mock_value
1010

1111
from ibex_bluesky_core.devices.block import (
1212
GLOBAL_MOVING_FLAG_PRE_WAIT,
@@ -365,6 +365,8 @@ async def test_block_mot_set_outside_limits(mot_block):
365365

366366
set_mock_value(mot_block.user_setpoint, 10)
367367
set_mock_value(mot_block.velocity, 10)
368+
set_mock_value(mot_block.dial_high_limit_travel, 15)
369+
set_mock_value(mot_block.dial_low_limit_travel, 5)
368370
set_mock_value(mot_block.high_limit_travel, 15)
369371
set_mock_value(mot_block.low_limit_travel, 5)
370372
with pytest.raises(err):

tests/devices/test_dae.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
import scipp as sc
1010
import scipp.testing
1111
from bluesky.run_engine import RunEngine
12-
from ophyd_async.testing import get_mock_put, set_mock_value
12+
from ophyd_async.core import get_mock_put, set_mock_value
1313

1414
from ibex_bluesky_core.devices import compress_and_hex, dehex_and_decompress
1515
from ibex_bluesky_core.devices.dae import (

tests/devices/test_reflectometry.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@
55
import bluesky.plan_stubs as bps
66
import numpy as np
77
import pytest
8+
from ophyd_async.core import callback_on_mock_put, get_mock_put, set_mock_value
89
from ophyd_async.plan_stubs import ensure_connected
9-
from ophyd_async.testing import callback_on_mock_put, get_mock_put, set_mock_value
1010

1111
from ibex_bluesky_core.devices import NoYesChoice
1212
from ibex_bluesky_core.devices.dae import Dae

tests/plans/test_det_map_align.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,7 @@
33

44
import numpy as np
55
import pytest
6-
from ophyd_async.core import soft_signal_rw
7-
from ophyd_async.testing import callback_on_mock_put, set_mock_value
6+
from ophyd_async.core import callback_on_mock_put, set_mock_value, soft_signal_rw
87

98
from ibex_bluesky_core.devices.simpledae import (
109
PeriodPerPointController,

tests/plans/test_init.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@
77
import pytest
88
from bluesky.preprocessors import run_decorator
99
from ophyd_async.plan_stubs import ensure_connected
10+
from ophyd_async.core import callback_on_mock_put, get_mock_put, set_mock_value
1011
from ophyd_async.sim import SimMotor
11-
from ophyd_async.testing import callback_on_mock_put, get_mock_put, set_mock_value
1212

1313
from ibex_bluesky_core.devices.block import BlockMot, BlockR, BlockRw
1414
from ibex_bluesky_core.devices.simpledae import (

tests/test_plan_stubs.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,9 @@
99
from bluesky import RunEngine
1010
from bluesky import plan_stubs as bps
1111
from bluesky.utils import Msg
12+
from ophyd_async.core import get_mock_put, set_mock_value
1213
from ophyd_async.epics.motor import UseSetMode
1314
from ophyd_async.plan_stubs import ensure_connected
14-
from ophyd_async.testing import get_mock_put, set_mock_value
1515

1616
from ibex_bluesky_core.devices import NoYesChoice, compress_and_hex, dehex_and_decompress
1717
from ibex_bluesky_core.devices.block import BlockMot

0 commit comments

Comments
 (0)