upleb.uk

Public git repos — served from a NIP-34 GRASP relay at git.upleb.uk

summaryrefslogtreecommitdiff
path: root/tests/semantic/test_mutations.py
diff options
context:
space:
mode:
Diffstat (limited to 'tests/semantic/test_mutations.py')
-rw-r--r--tests/semantic/test_mutations.py7
1 files changed, 5 insertions, 2 deletions
diff --git a/tests/semantic/test_mutations.py b/tests/semantic/test_mutations.py
index cce2b723a..0caca1d46 100644
--- a/tests/semantic/test_mutations.py
+++ b/tests/semantic/test_mutations.py
@@ -103,8 +103,11 @@ MUTATIONS = [
103 103
104 104
105def run_semantics(tools_dir): 105def run_semantics(tools_dir):
106 env = dict(os.environ, LEONIDA_TOOLS_DIR=tools_dir, PYTHONDONTWRITEBYTECODE="1") 106 # The child finds test_ps_semantics through PYTHONPATH, not cwd=HERE: Windows refuses a working directory longer
107 p = subprocess.run([sys.executable, "-m", "unittest", "test_ps_semantics", "-v"], cwd=HERE, env=env, 107 # than 258 characters (WinError 267), which a checkout in a deep folder reaches.
108 path = os.pathsep.join(filter(None, [HERE, os.environ.get("PYTHONPATH")]))
109 env = dict(os.environ, LEONIDA_TOOLS_DIR=tools_dir, PYTHONDONTWRITEBYTECODE="1", PYTHONPATH=path)
110 p = subprocess.run([sys.executable, "-m", "unittest", "test_ps_semantics", "-v"], env=env,
108 capture_output=True, text=True, timeout=300) 111 capture_output=True, text=True, timeout=300)
109 return p.returncode, p.stdout + p.stderr 112 return p.returncode, p.stdout + p.stderr
110 113