Skip to content

Commit f471133

Browse files
committed
fix: tests
Now that process gets replaced on UNIX, tests were not running (pytest got replaced with the first script invocation and returned success).
1 parent 66eddd4 commit f471133

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

tests/test_cmake.py

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515

1616
from . import push_argv
1717

18-
all_tools = pytest.mark.parametrize("tool", ["cmake", "cpack", "ctest"])
18+
all_tools = pytest.mark.parametrize("tool", ["ccmake", "cmake", "cpack", "ctest"])
1919

2020

2121
def _run(program, args):
@@ -27,11 +27,13 @@ def _run(program, args):
2727

2828

2929
@all_tools
30-
def test_cmake_module(tool):
30+
def test_cmake_module(tool, monkeypatch):
31+
monkeypatch.setattr(sys, "platform", "win32") # do not use os.execl
3132
_run(tool, ["--version"])
3233

3334

34-
def test_cmake_https(tmpdir):
35+
def test_cmake_https(tmpdir, monkeypatch):
36+
monkeypatch.setattr(sys, "platform", "win32") # do not use os.execl
3537
test_script = tmpdir.join("cmake-test-https-download.cmake")
3638
test_script.write(textwrap.dedent(
3739
"""

0 commit comments

Comments
 (0)