From 92401d874cf3aea1e5a0bd7313379fdd92f5056d Mon Sep 17 00:00:00 2001 From: Dominic Oram Date: Wed, 18 Sep 2024 16:17:50 +0100 Subject: [PATCH] Refactor test --- .../hyperion/experiment_plans/test_rotation_scan_plan.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/unit_tests/hyperion/experiment_plans/test_rotation_scan_plan.py b/tests/unit_tests/hyperion/experiment_plans/test_rotation_scan_plan.py index fbfc00d91..941dfbfde 100644 --- a/tests/unit_tests/hyperion/experiment_plans/test_rotation_scan_plan.py +++ b/tests/unit_tests/hyperion/experiment_plans/test_rotation_scan_plan.py @@ -238,9 +238,9 @@ async def test_rotation_plan_moves_aperture_correctly( aperture_scatterguard: ApertureScatterguard = ( run_full_rotation_plan.aperture_scatterguard ) - assert ( - await aperture_scatterguard.selected_aperture.get_value() == ApertureValue.SMALL - ) + reading = await aperture_scatterguard.read() + aperture_state = reading[aperture_scatterguard.selected_aperture.name]["value"] + assert aperture_state == ApertureValue.SMALL async def test_rotation_plan_smargon_doesnt_move_xyz_if_not_given_in_params(