Skip to content

Commit 0c86c0c

Browse files
committed
Ensure correct Python run on Windows
1 parent e7e55b0 commit 0c86c0c

1 file changed

Lines changed: 6 additions & 2 deletions

File tree

spin/tests/test_build_cmds.py

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ def test_run_stdout():
7070
"""Ensure `spin run` only includes command output on stdout."""
7171
p = spin(
7272
"run",
73-
"python",
73+
sys.executable,
7474
"-c",
7575
"import sys; del sys.path[0]; import example_pkg; print(example_pkg.__version__)",
7676
)
@@ -132,7 +132,11 @@ def test_spin_install():
132132
with tempfile.TemporaryDirectory() as d:
133133
os.chdir(d)
134134
p = run(
135-
["python", "-c", "import example_pkg; print(example_pkg.__version__)"],
135+
[
136+
sys.executable,
137+
"-c",
138+
"import example_pkg; print(example_pkg.__version__)",
139+
],
136140
stdout=subprocess.PIPE,
137141
)
138142
assert stdout(p) == "0.0.0dev0"

0 commit comments

Comments
 (0)