Skip to content

Commit

Permalink
deleted test debug message
Browse files Browse the repository at this point in the history
  • Loading branch information
ZohebShaikh committed Oct 24, 2024
1 parent 492d303 commit 9b63dc6
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 19 deletions.
7 changes: 3 additions & 4 deletions src/ophyd_async/epics/adaravis/_aravis_controller.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,6 @@
)
from ophyd_async.core._status import AsyncStatus
from ophyd_async.epics import adcore
from ophyd_async.epics.adcore._core_logic import (
start_acquiring_driver_and_ensure_status,
)

from ._aravis_io import AravisDriverIO, AravisTriggerMode, AravisTriggerSource

Expand Down Expand Up @@ -50,7 +47,9 @@ async def prepare(self, trigger_info: TriggerInfo):
)

async def arm(self):
self._arm_status = await start_acquiring_driver_and_ensure_status(self._drv)
self._arm_status = await adcore.start_acquiring_driver_and_ensure_status(
self._drv
)

async def wait_for_idle(self):
if self._arm_status:
Expand Down
9 changes: 0 additions & 9 deletions tests/core/test_signal.py
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,6 @@ async def wait_and_set_proceeds():

async def check_set_and_wait():
await set_and_wait_for_value(signal, 1, timeout=0.1)
await wait_for_value(signal, 1, timeout=0.1)

await asyncio.gather(wait_and_set_proceeds(), check_set_and_wait())
assert await signal.get_value() == 1
Expand All @@ -207,8 +206,6 @@ async def check_set_and_wait():
await set_and_wait_for_other_value(
set_signal, 1, match_signal, "test", timeout=100
)
await wait_for_value(set_signal, 1, timeout=100)
await wait_for_value(match_signal, "test", timeout=100)

await asyncio.gather(wait_and_set_read(), check_set_and_wait())
assert await set_signal.get_value() == 1
Expand Down Expand Up @@ -282,9 +279,6 @@ def less_than_42(v):
assert await time_taken_by(wait_for_value(signal, less_than_42, timeout=2)) < 0.1


async def test_set_and_wait_for_value(): ...


async def set_signal_value(signal_1: SignalRW, signal_2: SignalRW):
set_mock_value(signal_1, 1)
set_mock_value(signal_2, 2)
Expand Down Expand Up @@ -364,9 +358,6 @@ async def test_create_soft_signal(signal_method, signal_class):
assert (await signal.get_value()) == INITIAL_VALUE


# write code to add two numbers


async def test_soft_signal_numpy():
float_signal = soft_signal_rw(numpy.float64, numpy.float64(1), "float_signal")
int_signal = soft_signal_rw(numpy.int32, numpy.int32(1), "int_signal")
Expand Down
9 changes: 3 additions & 6 deletions tests/epics/test_motor.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,10 @@
SignalRW,
callback_on_mock_put,
mock_puts_blocked,
observe_value,
set_mock_put_proceeds,
set_mock_value,
)
from ophyd_async.core._signal import observe_signals_values
from ophyd_async.epics import motor

# Long enough for multiple asyncio event loop cycles to run so
Expand Down Expand Up @@ -279,13 +279,10 @@ async def test_prepare(
set_mock_value(sim_motor.high_limit_travel, 20)
set_mock_value(sim_motor.max_velocity, 10)
fake_set_signal = SignalRW(MockSignalBackend(float))
fake_other_set_signal = SignalRW(MockSignalBackend(float))

async def wait_for_set(_):
async for signal, value in observe_signals_values(
fake_other_set_signal, fake_set_signal, timeout=1
):
if signal == fake_set_signal and value == target_position:
async for value in observe_value(fake_set_signal, timeout=1):
if value == target_position:
break

sim_motor.set = AsyncMock(side_effect=wait_for_set)
Expand Down

0 comments on commit 9b63dc6

Please sign in to comment.