@@ -33,7 +33,7 @@ def asyncio_ioc():
3333@pytest .mark .asyncio
3434async def test_asyncio_ioc (asyncio_ioc ):
3535 import asyncio
36- from aioca import caget , caput , camonitor , CANothing , _catools
36+ from aioca import caget , caput , camonitor , CANothing , _catools , FORMAT_CTRL
3737 # Unregister the aioca atexit handler as it conflicts with the one installed
3838 # by cothread. If we don't do this we get a seg fault. This is not a problem
3939 # in production as we won't mix aioca and cothread, but we do mix them in
@@ -48,7 +48,10 @@ async def test_asyncio_ioc(asyncio_ioc):
4848 m = camonitor (PV_PREFIX + ":SIN" , q .put , notify_disconnect = True )
4949 assert len (await asyncio .wait_for (q .get (), 1 )) == 4
5050 # AO
51- assert await caget (PV_PREFIX + ":AO2" ) == 12.45
51+ ao_val = await caget (PV_PREFIX + ":AO2" , format = FORMAT_CTRL )
52+ assert ao_val == 0
53+ assert ao_val .severity == 3 # INVALID
54+ assert ao_val .status == 17 # UDF
5255 await caput (PV_PREFIX + ":AO2" , 3.56 , wait = True )
5356 await asyncio .sleep (0.1 )
5457 assert await caget (PV_PREFIX + ":AI" ) == 12.34
@@ -70,7 +73,7 @@ async def test_asyncio_ioc(asyncio_ioc):
7073 # check closed and output
7174 assert "%s:SINN.VAL 1024 -> 4" % PV_PREFIX in out
7275 assert 'update_sin_wf 4' in out
73- assert "%s:AO2.VAL 12.45 -> 3.56" % PV_PREFIX in out
76+ assert "%s:AO2.VAL 0 -> 3.56" % PV_PREFIX in out
7477 assert 'async update 3.56' in out
7578 assert 'Starting iocInit' in err
7679 assert 'iocRun: All initialization complete' in err
0 commit comments