diff --git a/tests/test_cmd.py b/tests/test_cmd.py index cbb1b430..26dc7a31 100644 --- a/tests/test_cmd.py +++ b/tests/test_cmd.py @@ -2,6 +2,7 @@ # SPDX-License-Identifier: Apache-2.0 import subprocess as sp +from sys import executable as python from textwrap import dedent @@ -21,8 +22,8 @@ def test_c_args(): def test_reproducible_gensym(): - out, err = once = cmd(["python", "-m", "hissp", "-c", '(print `$#G `($#G $#G))']) - again = cmd(["python", "-m", "hissp", "-c", '(print `$#G `($#G $#G))']) + out, err = once = cmd([python, "-m", "hissp", "-c", "(print `$#G `($#G $#G))"]) + again = cmd([python, "-m", "hissp", "-c", "(print `$#G `($#G $#G))"]) assert once == again assert err == "" assert "_Qz" in out @@ -30,8 +31,8 @@ def test_reproducible_gensym(): def test_unique_gensyms(): err = [None] * 2 - once, err[0] = cmd(["python", "-m", "hissp", "-c", '(print `$#G `($#G $#G))']) - again, err[1] = cmd(["python", "-m", "hissp", "-c", '0 (print `$#G `($#G $#G))']) + once, err[0] = cmd([python, "-m", "hissp", "-c", "(print `$#G `($#G $#G))"]) + again, err[1] = cmd([python, "-m", "hissp", "-c", "0 (print `$#G `($#G $#G))"]) assert err == ["", ""] assert once != again assert "_Qz" in once