diff --git a/tests/unit/modules/test_pip.py b/tests/unit/modules/test_pip.py index ecd09a309a..cb9f88c966 100644 --- a/tests/unit/modules/test_pip.py +++ b/tests/unit/modules/test_pip.py @@ -301,6 +301,8 @@ class PipTestCase(TestCase, LoaderModuleMockMixin): if salt.utils.is_windows(): venv_path = 'c:\\test_env' bin_path = os.path.join(venv_path, 'Scripts', 'pip.exe') + if six.PY2: + bin_path = bin_path.encode('string-escape') else: venv_path = '/test_env' bin_path = os.path.join(venv_path, 'bin', 'pip')