]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
bpo-45506: Stop skipping test_embed. (gh-29300)
authorEric Snow <ericsnowcurrently@gmail.com>
Wed, 3 Nov 2021 17:47:16 +0000 (11:47 -0600)
committerGitHub <noreply@github.com>
Wed, 3 Nov 2021 17:47:16 +0000 (11:47 -0600)
In gh-29063 I ended up disabling test_embed on non-Windows by accident. This gets it running again.

https://bugs.python.org/issue45506

Lib/test/test_embed.py

index 3a00efa5799b95890dd984ecaf641350d75fde2a..a0d61504f427d2d1ca12e9b93fc45dbb05831c4f 100644 (file)
@@ -58,10 +58,12 @@ class EmbeddingTestsMixin:
             ext = ("_d" if debug_build(sys.executable) else "") + ".exe"
             exename += ext
             exepath = builddir
+            expecteddir = support.REPO_ROOT
         else:
             exepath = os.path.join(builddir, 'Programs')
+            expecteddir = os.path.join(support.REPO_ROOT, 'Programs')
         self.test_exe = exe = os.path.join(exepath, exename)
-        if exepath != support.REPO_ROOT or not os.path.exists(exe):
+        if exepath != expecteddir or not os.path.exists(exe):
             self.skipTest("%r doesn't exist" % exe)
         # This is needed otherwise we get a fatal error:
         # "Py_Initialize: Unable to get the locale encoding