'tox -e py310' results in several errors such as:
======================================================================
FAIL: networking_hyperv.tests.unit.neutron.agent.test_layer2.TestLayer2Agent.test_create_event_listeners
networking_hyperv.tests.unit.neutron.agent.test_layer2.TestLayer2Agent.test_create_event_listeners
----------------------------------------------------------------------
testtools.testresult.real._StringException: Traceback (most recent call last):
File "/usr/lib/python3.10/unittest/mock.py", line 1369, in patched
return func(*newargs, **newkeywargs)
File "/<<PKGBUILDDIR>>/networking_hyperv/tests/unit/neutron/agent/test_layer2.py", line 386, in test_create_event_listeners
self._agent._create_event_listeners()
File "/<<PKGBUILDDIR>>/networking_hyperv/neutron/agent/layer2.py", line 239, in _create_event_listeners
listener = self._utils.get_vnic_event_listener(event_type)
File "/usr/lib/python3/dist-packages/oslotest/mock_fixture.py", line 80, in __getattr__
_lazy_autospec_method(attr, original_attr, eat_self)
File "/usr/lib/python3/dist-packages/oslotest/mock_fixture.py", line 27, in _lazy_autospec_method
_lazy_autospec = mock.create_autospec(original_method)
File "/usr/lib/python3.10/unittest/mock.py", line 2647, in create_autospec
raise InvalidSpecError(f'Cannot autospec a Mock object. '
unittest.mock.InvalidSpecError: Cannot autospec a Mock object. [object=<_AutospecMagicMock name='_get_class().get_vnic_event_listener' id='140569743232640'>]
A similar issue is being fixed in ironic at https://review.opendev.org/c/openstack/ironic/+/821370
Fairly certain this is not an oslotest issue after looking at the documentation at: /docs.openstack .org/oslotest/ latest/ user/mock- autospec. html#mockautosp ecfixture
https:/