1
0
forked from pool/python-mutmut
python-mutmut/python-mutmut.spec

101 lines
2.9 KiB
RPMSpec
Raw Normal View History

#
# spec file for package python-mutmut
#
# Copyright (c) 2022 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
# tri.declarative is Python 3 only
%define skip_python2 1
# hammett requires python 3.7 or later
%define skip_python36 1
Name: python-mutmut
Accepting request 789811 from home:pgajdos:python - version update to 2.0.0 * New execution model. This should result in some modest speed improvements when using pytest. * A special execution mode when using the hammett test runner. This is MUCH MUCH faster. Please try it! * Dropped support for python < 3.7. If you need to use mutmut on older versions of python, please use mutmut 1.9.0 * Some other speed improvements. * `mutmut run 7` will always rerun the mutant `7` * `mutmut show <filename>` to show all mutants for that file * `mutmut run <filename>` to run mutation testing on that file * New experimental plugin system: create a file `mutmut_config.py` in your base directory. In it you can have an `init()` function, and a `pre_mutation(context)` function. You can set `context.skip = True` to skip a mutant, and you can modify `context.config.runner`, this is useful to limit the tests. Check out the `Context` class for what information you get. * Better display of `mutmut show`/`mutmut result` * Fixed a spurious mutant on assigning a local variable with type annotations * mutmut now will rerun tests without mutation when tests have changed. This avoids a common pitfall of introducing a failing test and then having all mutants killed incorrectly * Added `mutmut html` report generation. * Bugfix for multiple assignment. Mutmut used to not handle `foo = bar = baz` correctly (Thanks Roxane Bellot!) * Bugfix for incorrect mutation of "in" operator (Thanks Roxane Bellot!) * Fixed bug where a mutant survived in the internal AST too long. This could cause mutmut to apply more than one mutant at a time. * Vastly improved startup performance when resuming a mutation run. * Added new experimental feature for advanced config at runtime of mutations - modified patches % pr_134.patch (extended) - deleted patches - no-direct-python-call.patch (merged to pr_134.patch) OBS-URL: https://build.opensuse.org/request/show/789811 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-mutmut?expand=0&rev=5
2020-03-31 08:24:04 +02:00
Version: 2.0.0
Release: 0
Summary: Python mutation testing
License: BSD-3-Clause
URL: https://github.com/boxed/mutmut
Source: https://github.com/boxed/mutmut/archive/%{version}.tar.gz
Patch1: pr_134.patch
BuildRequires: %{python_module setuptools}
BuildRequires: fdupes
BuildRequires: python-rpm-macros
Requires: python-click
Requires: python-glob2
Accepting request 789811 from home:pgajdos:python - version update to 2.0.0 * New execution model. This should result in some modest speed improvements when using pytest. * A special execution mode when using the hammett test runner. This is MUCH MUCH faster. Please try it! * Dropped support for python < 3.7. If you need to use mutmut on older versions of python, please use mutmut 1.9.0 * Some other speed improvements. * `mutmut run 7` will always rerun the mutant `7` * `mutmut show <filename>` to show all mutants for that file * `mutmut run <filename>` to run mutation testing on that file * New experimental plugin system: create a file `mutmut_config.py` in your base directory. In it you can have an `init()` function, and a `pre_mutation(context)` function. You can set `context.skip = True` to skip a mutant, and you can modify `context.config.runner`, this is useful to limit the tests. Check out the `Context` class for what information you get. * Better display of `mutmut show`/`mutmut result` * Fixed a spurious mutant on assigning a local variable with type annotations * mutmut now will rerun tests without mutation when tests have changed. This avoids a common pitfall of introducing a failing test and then having all mutants killed incorrectly * Added `mutmut html` report generation. * Bugfix for multiple assignment. Mutmut used to not handle `foo = bar = baz` correctly (Thanks Roxane Bellot!) * Bugfix for incorrect mutation of "in" operator (Thanks Roxane Bellot!) * Fixed bug where a mutant survived in the internal AST too long. This could cause mutmut to apply more than one mutant at a time. * Vastly improved startup performance when resuming a mutation run. * Added new experimental feature for advanced config at runtime of mutations - modified patches % pr_134.patch (extended) - deleted patches - no-direct-python-call.patch (merged to pr_134.patch) OBS-URL: https://build.opensuse.org/request/show/789811 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-mutmut?expand=0&rev=5
2020-03-31 08:24:04 +02:00
Requires: python-hammett
Requires: python-junit-xml >= 1.8
Requires: python-parso
Requires: python-pony
Accepting request 789811 from home:pgajdos:python - version update to 2.0.0 * New execution model. This should result in some modest speed improvements when using pytest. * A special execution mode when using the hammett test runner. This is MUCH MUCH faster. Please try it! * Dropped support for python < 3.7. If you need to use mutmut on older versions of python, please use mutmut 1.9.0 * Some other speed improvements. * `mutmut run 7` will always rerun the mutant `7` * `mutmut show <filename>` to show all mutants for that file * `mutmut run <filename>` to run mutation testing on that file * New experimental plugin system: create a file `mutmut_config.py` in your base directory. In it you can have an `init()` function, and a `pre_mutation(context)` function. You can set `context.skip = True` to skip a mutant, and you can modify `context.config.runner`, this is useful to limit the tests. Check out the `Context` class for what information you get. * Better display of `mutmut show`/`mutmut result` * Fixed a spurious mutant on assigning a local variable with type annotations * mutmut now will rerun tests without mutation when tests have changed. This avoids a common pitfall of introducing a failing test and then having all mutants killed incorrectly * Added `mutmut html` report generation. * Bugfix for multiple assignment. Mutmut used to not handle `foo = bar = baz` correctly (Thanks Roxane Bellot!) * Bugfix for incorrect mutation of "in" operator (Thanks Roxane Bellot!) * Fixed bug where a mutant survived in the internal AST too long. This could cause mutmut to apply more than one mutant at a time. * Vastly improved startup performance when resuming a mutation run. * Added new experimental feature for advanced config at runtime of mutations - modified patches % pr_134.patch (extended) - deleted patches - no-direct-python-call.patch (merged to pr_134.patch) OBS-URL: https://build.opensuse.org/request/show/789811 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-mutmut?expand=0&rev=5
2020-03-31 08:24:04 +02:00
Requires: python-setuptools
Requires: python-tri.declarative >= 3.0.0
Requires(post): update-alternatives
Requires(postun):update-alternatives
Recommends: python-coverage
Recommends: python-pytest
Suggests: python-pytest-cov
BuildArch: noarch
# SECTION test requirements
BuildRequires: %{python_module click}
BuildRequires: %{python_module coverage}
BuildRequires: %{python_module glob2}
Accepting request 789811 from home:pgajdos:python - version update to 2.0.0 * New execution model. This should result in some modest speed improvements when using pytest. * A special execution mode when using the hammett test runner. This is MUCH MUCH faster. Please try it! * Dropped support for python < 3.7. If you need to use mutmut on older versions of python, please use mutmut 1.9.0 * Some other speed improvements. * `mutmut run 7` will always rerun the mutant `7` * `mutmut show <filename>` to show all mutants for that file * `mutmut run <filename>` to run mutation testing on that file * New experimental plugin system: create a file `mutmut_config.py` in your base directory. In it you can have an `init()` function, and a `pre_mutation(context)` function. You can set `context.skip = True` to skip a mutant, and you can modify `context.config.runner`, this is useful to limit the tests. Check out the `Context` class for what information you get. * Better display of `mutmut show`/`mutmut result` * Fixed a spurious mutant on assigning a local variable with type annotations * mutmut now will rerun tests without mutation when tests have changed. This avoids a common pitfall of introducing a failing test and then having all mutants killed incorrectly * Added `mutmut html` report generation. * Bugfix for multiple assignment. Mutmut used to not handle `foo = bar = baz` correctly (Thanks Roxane Bellot!) * Bugfix for incorrect mutation of "in" operator (Thanks Roxane Bellot!) * Fixed bug where a mutant survived in the internal AST too long. This could cause mutmut to apply more than one mutant at a time. * Vastly improved startup performance when resuming a mutation run. * Added new experimental feature for advanced config at runtime of mutations - modified patches % pr_134.patch (extended) - deleted patches - no-direct-python-call.patch (merged to pr_134.patch) OBS-URL: https://build.opensuse.org/request/show/789811 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-mutmut?expand=0&rev=5
2020-03-31 08:24:04 +02:00
BuildRequires: %{python_module hammett}
BuildRequires: %{python_module junit-xml >= 1.8}
BuildRequires: %{python_module parso}
BuildRequires: %{python_module pony}
BuildRequires: %{python_module pytest >= 2.8.7}
BuildRequires: %{python_module pytest-cov}
BuildRequires: %{python_module tri.declarative >= 3.0.0}
BuildRequires: %{python_module whatthepatch >= 0.0.5}
BuildRequires: ed
BuildRequires: patch
# /SECTION
%python_subpackages
%description
Python mutation testing.
%prep
%setup -q -n mutmut-%{version}
%autopatch -p1
sed -i 's/==/>=/' *requirements.txt
# Remove maximum pins any anything that follows
sed -Ei 's/,?<=?.*$//' test_requirements.txt
sed -i '1{/^#!/d}' mutmut/__main__.py
%build
%python_build
%install
%python_install
%python_clone -a %{buildroot}%{_bindir}/mutmut
%python_expand %fdupes %{buildroot}%{$python_sitelib}
%check
Accepting request 789811 from home:pgajdos:python - version update to 2.0.0 * New execution model. This should result in some modest speed improvements when using pytest. * A special execution mode when using the hammett test runner. This is MUCH MUCH faster. Please try it! * Dropped support for python < 3.7. If you need to use mutmut on older versions of python, please use mutmut 1.9.0 * Some other speed improvements. * `mutmut run 7` will always rerun the mutant `7` * `mutmut show <filename>` to show all mutants for that file * `mutmut run <filename>` to run mutation testing on that file * New experimental plugin system: create a file `mutmut_config.py` in your base directory. In it you can have an `init()` function, and a `pre_mutation(context)` function. You can set `context.skip = True` to skip a mutant, and you can modify `context.config.runner`, this is useful to limit the tests. Check out the `Context` class for what information you get. * Better display of `mutmut show`/`mutmut result` * Fixed a spurious mutant on assigning a local variable with type annotations * mutmut now will rerun tests without mutation when tests have changed. This avoids a common pitfall of introducing a failing test and then having all mutants killed incorrectly * Added `mutmut html` report generation. * Bugfix for multiple assignment. Mutmut used to not handle `foo = bar = baz` correctly (Thanks Roxane Bellot!) * Bugfix for incorrect mutation of "in" operator (Thanks Roxane Bellot!) * Fixed bug where a mutant survived in the internal AST too long. This could cause mutmut to apply more than one mutant at a time. * Vastly improved startup performance when resuming a mutation run. * Added new experimental feature for advanced config at runtime of mutations - modified patches % pr_134.patch (extended) - deleted patches - no-direct-python-call.patch (merged to pr_134.patch) OBS-URL: https://build.opensuse.org/request/show/789811 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-mutmut?expand=0&rev=5
2020-03-31 08:24:04 +02:00
%pytest
%post
%python_install_alternative mutmut
%postun
%python_uninstall_alternative mutmut
%files %{python_files}
%doc README.rst
%license LICENSE
%python_alternative %{_bindir}/mutmut
%{python_sitelib}/*
%changelog