Skip to content

Commit

Permalink
Add slits pytest tag to relevant unit tests
Browse files Browse the repository at this point in the history
  • Loading branch information
dan-fernandes committed Oct 19, 2023
1 parent f2edd56 commit ac51d0d
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions tests/devices/unit_tests/test_slit_interface.py
Original file line number Diff line number Diff line change
@@ -1,21 +1,23 @@
from dodal.devices.slits.S5_BL02J_AL_SLITS_95 import S5_BL02J_AL_SLITS_95 as Slit

import random
import pytest


def parsed_read(component):
description = component.describe()
res = component.read()
return res[description["value"]["source"]]["value"]
return res[description[component.name]["source"]]["value"]


@pytest.mark.slits
def test_set():
slit = Slit(name="slit", prefix="BL02J-AL-SLITS-95:")
slit.wait_for_connection()

target_values = [round(random.random(), 3) for i in range(4)]

status = slit.set(*target_values)
status = slit.set(target_values)
status.wait()

results = [
Expand Down

0 comments on commit ac51d0d

Please sign in to comment.