Skip to content

Commit d882765

Browse files
committed
test: amend p4p tests to use new pvi structure
1 parent 480bab8 commit d882765

File tree

1 file changed

+6
-11
lines changed

1 file changed

+6
-11
lines changed

tests/transport/epics/pva/test_p4p.py

Lines changed: 6 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -51,12 +51,11 @@ async def test_ioc(p4p_subprocess: tuple[str, Queue]):
5151
assert _child_vector_pvi["display"] == {"description": "some child vector"}
5252
assert _child_vector_pvi["value"] == {
5353
"vector_attribute": {"r": f"{pv_prefix}:Child:VectorAttribute"},
54-
"child": {
55-
"d": {"v1": f"{pv_prefix}:Child:1:PVI", "v2": f"{pv_prefix}:Child:2:PVI"}
56-
},
54+
"v1": {"d": f"{pv_prefix}:Child:1:PVI"},
55+
"v2": {"d": f"{pv_prefix}:Child:2:PVI"},
5756
}
5857

59-
child_pvi_pv = _child_vector_pvi["value"]["child"]["d"]["v1"]
58+
child_pvi_pv = _child_vector_pvi["value"]["v1"]["d"]
6059
_child_pvi = await ctxt.get(child_pvi_pv)
6160
assert isinstance(_child_pvi, Value)
6261
child_pvi = _child_pvi.todict()
@@ -370,13 +369,9 @@ class SomeController(Controller):
370369
"userTag": 0,
371370
},
372371
"value": {
373-
"child": {
374-
"d": {
375-
"v0": f"{pv_prefix}:Child:0:PVI",
376-
"v1": f"{pv_prefix}:Child:1:PVI",
377-
"v2": f"{pv_prefix}:Child:2:PVI",
378-
},
379-
},
372+
"v0": {"d": f"{pv_prefix}:Child:0:PVI"},
373+
"v1": {"d": f"{pv_prefix}:Child:1:PVI"},
374+
"v2": {"d": f"{pv_prefix}:Child:2:PVI"},
380375
},
381376
}
382377
assert len(child_child_controller_pvi) == 1

0 commit comments

Comments
 (0)