@@ -1405,30 +1405,17 @@ async def test_query_peer_properties_retry_timeout(nursery, dbus, sysnet):
14051405 assert res == 0
14061406
14071407""" Test RegisterVDMTypeSupport when no responders are registered """
1408- async def test_register_vdm_type_support_empty (mctpd ):
1409- ep = mctpd .network .endpoints [0 ]
1410- ep .eid = 12
1411- iface = mctpd .system .interfaces [0 ]
1412- await mctpd .system .add_route (mctpd .system .Route (ep .eid , 1 , iface = iface ))
1413- await mctpd .system .add_neighbour (
1414- mctpd .system .Neighbour (iface , ep .lladdr , ep .eid )
1415- )
1408+ async def test_register_vdm_type_support_empty (mctpd , routed_ep ):
1409+ ep = routed_ep
14161410
14171411 # Verify error response when no VDM is registered
14181412 cmd = MCTPControlCommand (True , 0 , 0x06 , bytes ([0x00 ]))
14191413 rsp = await ep .send_control (mctpd .network .mctp_socket , cmd )
14201414 assert rsp .hex (' ' ) == '00 06 02'
14211415
14221416""" Test RegisterVDMTypeSupport when a single PCIe VDM is registered """
1423- async def test_register_vdm_type_support_pcie_only (dbus , mctpd ):
1424- ep = mctpd .network .endpoints [0 ]
1425- ep .eid = 12
1426- iface = mctpd .system .interfaces [0 ]
1427- await mctpd .system .add_route (mctpd .system .Route (ep .eid , 1 , iface = iface ))
1428- await mctpd .system .add_neighbour (
1429- mctpd .system .Neighbour (iface , ep .lladdr , ep .eid )
1430- )
1431-
1417+ async def test_register_vdm_type_support_pcie_only (dbus , mctpd , routed_ep ):
1418+ ep = routed_ep
14321419 mctp = await mctpd_mctp_base_iface_obj (dbus )
14331420
14341421 # Register PCIe VDM: format=0x00, VID=0xABCD, command_set=0x0001
@@ -1446,15 +1433,8 @@ async def test_register_vdm_type_support_pcie_only(dbus, mctpd):
14461433 assert rsp .hex (' ' ) == '00 06 02'
14471434
14481435""" Test RegisterVDMTypeSupport when a single IANA VDM is registered """
1449- async def test_register_vdm_type_support_iana_only (dbus , mctpd ):
1450- ep = mctpd .network .endpoints [0 ]
1451- ep .eid = 12
1452- iface = mctpd .system .interfaces [0 ]
1453- await mctpd .system .add_route (mctpd .system .Route (ep .eid , 1 , iface = iface ))
1454- await mctpd .system .add_neighbour (
1455- mctpd .system .Neighbour (iface , ep .lladdr , ep .eid )
1456- )
1457-
1436+ async def test_register_vdm_type_support_iana_only (dbus , mctpd , routed_ep ):
1437+ ep = routed_ep
14581438 mctp = await mctpd_mctp_base_iface_obj (dbus )
14591439
14601440 # Register IANA VDM: format=0x01, VID=0x1234ABCD, command_set=0x5678
@@ -1467,14 +1447,8 @@ async def test_register_vdm_type_support_iana_only(dbus, mctpd):
14671447 assert rsp .hex (' ' ) == '00 06 00 ff 01 12 34 ab cd 56 78'
14681448
14691449""" Test RegisterVDMTypeSupport with dbus disconnect """
1470- async def test_register_vdm_type_support_dbus_disconnect (mctpd ):
1471- ep = mctpd .network .endpoints [0 ]
1472- ep .eid = 12
1473- iface = mctpd .system .interfaces [0 ]
1474- await mctpd .system .add_route (mctpd .system .Route (ep .eid , 1 , iface = iface ))
1475- await mctpd .system .add_neighbour (
1476- mctpd .system .Neighbour (iface , ep .lladdr , ep .eid )
1477- )
1450+ async def test_register_vdm_type_support_dbus_disconnect (mctpd , routed_ep ):
1451+ ep = routed_ep
14781452
14791453 # Verify error response when no VDM is registered
14801454 cmd = MCTPControlCommand (True , 0 , 0x06 , bytes ([0x00 ]))
@@ -1503,15 +1477,8 @@ async def test_register_vdm_type_support_dbus_disconnect(mctpd):
15031477
15041478""" Test RegisterVDMTypeSupport error handling """
15051479async def test_register_vdm_type_support_errors (dbus , mctpd ):
1506- ep = mctpd .network .endpoints [0 ]
1507- ep .eid = 12
1508- iface = mctpd .system .interfaces [0 ]
1509- await mctpd .system .add_route (mctpd .system .Route (ep .eid , 1 , iface = iface ))
1510- await mctpd .system .add_neighbour (
1511- mctpd .system .Neighbour (iface , ep .lladdr , ep .eid )
1512- )
1513-
15141480 mctp = await mctpd_mctp_base_iface_obj (dbus )
1481+
15151482 # Verify DBus call fails with invalid format 0x02
15161483 v_type = asyncdbus .Variant ('q' , 0xABCD )
15171484 with pytest .raises (asyncdbus .errors .DBusError ) as ex :
0 commit comments