summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorCole Robinson <crobinso@redhat.com>2021-10-04 15:44:28 -0400
committerCole Robinson <crobinso@redhat.com>2021-10-04 16:04:44 -0400
commit758eb74ba3b687b6ed7e0af76865d6add8d96d06 (patch)
tree7c90788cf1a6a6d6a0bf71e6f7d1c427d6c0e07d /tests
parent79da19ad075392cab115e528799f32bb6e1f6a2a (diff)
downloadvirt-manager-758eb74ba3b687b6ed7e0af76865d6add8d96d06.tar.gz
Replace deprecated `imp` usage with `importlib`
Signed-off-by: Cole Robinson <crobinso@redhat.com>
Diffstat (limited to 'tests')
-rw-r--r--tests/__init__.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/tests/__init__.py b/tests/__init__.py
index 8496b82e..9e3a9bb8 100644
--- a/tests/__init__.py
+++ b/tests/__init__.py
@@ -3,7 +3,7 @@
# This work is licensed under the GNU GPLv2 or later.
# See the COPYING file in the top-level directory.
-import imp
+import importlib
import os
# Need to do this before any tests or virtinst import
@@ -18,8 +18,9 @@ os.environ.pop("LANGUAGE", None)
# pylint: disable=wrong-import-position
from virtinst import buildconfig
from virtinst import log, reset_logging
+
# This sets all the cli bits back to their defaults
-imp.reload(buildconfig)
+importlib.reload(buildconfig)
from tests import utils