openstack-python-openstackc.../openstackclient/tests/unit/common
Stephen Finucane 4c31284936 Fix tests on Python 3.12
We were seeing the following test failures on Python 3.12:

  openstackclient.tests.unit.common.test_module.TestModuleList.test_module_list_all
  openstackclient.tests.unit.common.test_module.TestModuleList.test_module_list_no_options

Both failures were caused by missing attributes of 'sys', e.g.

  AttributeError: module 'sys' has no attribute 'builtin_module_names'

Fix this by exposing the real 'sys' module as part of our mock of
'sys.modules'.

Change-Id: I17391a46f08896f49dccaf75ad685dab1375a03d
Signed-off-by: Stephen Finucane <stephenfin@redhat.com>
2024-05-10 11:16:56 +01:00
..
__init__.py move unit tests to new "unit" test module 2016-09-08 15:19:50 -07:00
test_availability_zone.py tests: Add compute v2 FakeClientMixin 2023-09-29 10:14:32 +01:00
test_clientmanager.py Blacken openstack.common 2023-05-10 10:51:30 +01:00
test_command.py Blacken openstack.common 2023-05-10 10:51:30 +01:00
test_configuration.py Blacken openstack.common 2023-05-10 10:51:30 +01:00
test_extension.py tests: Use central SDK client fake 2023-09-29 10:12:19 +01:00
test_limits.py tests: Add compute v2 FakeClientMixin 2023-09-29 10:14:32 +01:00
test_logs.py trivial: Prepare for pyupgrade pre-commit hook 2024-04-23 12:24:23 +01:00
test_module.py Fix tests on Python 3.12 2024-05-10 11:16:56 +01:00
test_progressbar.py Blacken openstack.common 2023-05-10 10:51:30 +01:00
test_project_cleanup.py trivial: Prepare for pyupgrade pre-commit hook 2024-04-23 12:24:23 +01:00
test_quota.py trivial: Prepare for pyupgrade pre-commit hook 2024-04-23 12:24:23 +01:00