2019-09-09 09:15:10 +02:00
|
|
|
From bd3866316949f8ba7162e0292be0776d6f51cf50 Mon Sep 17 00:00:00 2001
|
|
|
|
From: Maxime Lapointe <hunter_spawn@hotmail.com>
|
|
|
|
Date: Tue, 23 Jul 2019 08:55:15 -0400
|
|
|
|
Subject: [PATCH] Use sys.executable as default python executable
|
|
|
|
|
|
|
|
It's more likely to be the correct Python executable in case where someone specified the executable when running mutmut.
|
|
|
|
---
|
|
|
|
mutmut/__main__.py | 2 +-
|
|
|
|
1 file changed, 1 insertion(+), 1 deletion(-)
|
|
|
|
|
2020-03-31 08:24:04 +02:00
|
|
|
Index: mutmut-2.0.0/mutmut/__main__.py
|
2019-10-15 10:19:02 +02:00
|
|
|
===================================================================
|
2020-03-31 08:24:04 +02:00
|
|
|
--- mutmut-2.0.0.orig/mutmut/__main__.py 2020-03-26 09:45:09.000000000 +0100
|
|
|
|
+++ mutmut-2.0.0/mutmut/__main__.py 2020-03-30 16:01:03.781625630 +0200
|
|
|
|
@@ -101,7 +101,7 @@ null_out = open(os.devnull, 'w')
|
2019-09-09 09:15:10 +02:00
|
|
|
@config_from_setup_cfg(
|
|
|
|
dict_synonyms='',
|
2019-10-15 10:19:02 +02:00
|
|
|
paths_to_exclude='',
|
2020-03-31 08:24:04 +02:00
|
|
|
- runner='python -m pytest -x --assert=plain',
|
2019-09-09 09:15:10 +02:00
|
|
|
+ runner='"' + sys.executable + '" -m pytest -x',
|
2019-10-15 10:19:02 +02:00
|
|
|
tests_dir='tests/:test/',
|
2019-09-09 09:15:10 +02:00
|
|
|
pre_mutation=None,
|
|
|
|
post_mutation=None,
|
2020-03-31 08:24:04 +02:00
|
|
|
Index: mutmut-2.0.0/tests/test_main.py
|
|
|
|
===================================================================
|
|
|
|
--- mutmut-2.0.0.orig/tests/test_main.py 2020-03-26 09:45:09.000000000 +0100
|
|
|
|
+++ mutmut-2.0.0/tests/test_main.py 2020-03-30 16:03:15.066124033 +0200
|
|
|
|
@@ -94,8 +94,8 @@ def create_filesystem(tmpdir, file_to_mu
|
|
|
|
with open(join(test_dir, 'setup.cfg'), 'w') as f:
|
|
|
|
f.write("""
|
|
|
|
[mutmut]
|
|
|
|
-runner=python -m hammett -x
|
|
|
|
-""")
|
|
|
|
+runner={} -m hammett -x
|
|
|
|
+""".format(sys.executable))
|
|
|
|
|
|
|
|
with open(join(test_dir, "foo.py"), 'w') as f:
|
|
|
|
f.write(file_to_mutate_contents)
|