14
0
forked from pool/python-mutmut
Files
python-mutmut/pr_134.patch
Dirk Mueller fbf8a8c928 - update to 3.2.2:
* Fixed crash when running mutmut results
  * Read paths_to_mutate from config file
  * Mutate break to return to avoid timeouts
  * Added debug mode. Enable with debug=True in setup.cfg under
    [mutmut]
  * Fixed new test detection. The old code incorrectly detected
    new tests when there were none, creating a much slower
    interaction loop for fixing mutants.
  * And many more fixes
  * Timeouts for mutants implemented.
  * Browser: syntax highlighting for diff view
  * More fixes for generators.
  * Fix for src-style layout of projects.
  * Fixed bug where mutmut would recollect all tests on every
    run, slowing down startup.
  * Correctly handle mutation for generator functions (yield).
  * Fixed so that from __future__ lines are always first.
  * If no stats are collected exit directly, as that is a
    breaking error for mutation testing.
  * Changed name mangling to make mutants less likely to trigger
    name-based python magic, like in pytest where functions named
    test_* have special meaning.
  * Another attempt to get the pypi package to work
  * Another attempt to get the pypi package to work
  * Fixed missing requirement in install package
  * Fixed missing file from the install package
  * Fixed bad entrypoint definition
  * Ignore files that can't be parsed by parso
  * Missed a file in distribution, so browse command was broken.

OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-mutmut?expand=0&rev=15
2024-11-21 10:12:29 +00:00

39 lines
1.5 KiB
Diff

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(-)
Index: mutmut-2.0.0/mutmut/__main__.py
===================================================================
--- 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')
@config_from_setup_cfg(
dict_synonyms='',
paths_to_exclude='',
- runner='python -m pytest -x --assert=plain',
+ runner='"' + sys.executable + '" -m pytest -x',
tests_dir='tests/:test/',
pre_mutation=None,
post_mutation=None,
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)