Skip to content

Commit

Permalink
Use importlib
Browse files Browse the repository at this point in the history
  • Loading branch information
RazerM committed Jul 30, 2023
1 parent 19d57f8 commit 085a5ed
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion tests/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
:license: BSD, see LICENSE for more details.
"""
import functools
import importlib
import os
import sys
from contextlib import contextmanager
Expand Down Expand Up @@ -40,7 +41,7 @@ def get_total_delta_seconds(delta):
def require_module(module_name):
found = True
try:
__import__(module_name)
importlib.import_module(module_name)
except ImportError:
found = False

Expand Down

0 comments on commit 085a5ed

Please sign in to comment.