Skip to content
This repository was archived by the owner on Oct 12, 2023. It is now read-only.

Commit cbc6452

Browse files
williexutroydai
authored andcommitted
pylint import fix
1 parent b16236d commit cbc6452

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/azure_devtools/scenario_tests/patches.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,10 @@ def _shortcut_long_run_operation(*args, **kwargs): # pylint: disable=unused-arg
2323

2424

2525
def mock_in_unit_test(unit_test, target, replacement):
26-
import mock
26+
try:
27+
import unittest.mock as mock
28+
except ImportError:
29+
import mock
2730
import unittest
2831

2932
if not isinstance(unit_test, unittest.TestCase):

0 commit comments

Comments
 (0)