Skip to content

Commit

Permalink
TST #810 adjust for observed CI failure
Browse files Browse the repository at this point in the history
  • Loading branch information
prjemian committed Apr 4, 2024
1 parent edeef53 commit c18d860
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion apstools/devices/tests/test_positioner_soft_done.py
Original file line number Diff line number Diff line change
Expand Up @@ -263,6 +263,12 @@ def test_move_and_stop_nonzero(rbv, pos):

def test_move_and_stopped_early(rbv, pos):
def motion(target, delay, interrupt=False):
"""
Test moving pos to target. Update rbv after delay.
If interrupt is True, stop the move before it is done
(at a time that is less than the 'delay' value).
"""
timed_pause(0.1) # allow previous activities to settle down

t0 = time.time()
Expand All @@ -275,7 +281,7 @@ def motion(target, delay, interrupt=False):
rb_new = pos.readback.get(use_monitor=False)
arrived = math.isclose(rb_new, target, abs_tol=pos.actual_tolerance)
# fmt: on
if interrupt:
if interrupt and not status.done:
assert not status.done
assert not status.success
assert not arrived, f"{dt=:.3f}"
Expand Down

0 comments on commit c18d860

Please sign in to comment.