delete the require on coverage
This commit is contained in:
parent
4d376bd906
commit
b7dbf091e5
@ -0,0 +1,60 @@
|
|||||||
|
From fb770f4d748a5c334efa3ef251ff4f1524ac0c90 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Stephen Rosen <sirosen@globus.org>
|
||||||
|
Date: Fri, 18 Mar 2022 05:16:19 +0000
|
||||||
|
Subject: [PATCH] Remove install_requires dependency on 'coverage'
|
||||||
|
|
||||||
|
This can be traced back to an added dependency on code-cov (prior to
|
||||||
|
coverage) which doesn't appear to have been correct. It was added to
|
||||||
|
the installation requirements rather than the dev requirements.
|
||||||
|
It should be possible to use ``nose2`` in an environment without
|
||||||
|
``coverage`` installed (but not to use the coverage plugin).
|
||||||
|
|
||||||
|
As a result, `install_requires` can be removed entirely.
|
||||||
|
---
|
||||||
|
nose2/tests/functional/test_coverage.py | 7 +++++++
|
||||||
|
setup.py | 5 ++---
|
||||||
|
2 files changed, 9 insertions(+), 3 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/nose2/tests/functional/test_coverage.py b/nose2/tests/functional/test_coverage.py
|
||||||
|
index d98d5b4..1b96ae4 100644
|
||||||
|
--- a/nose2/tests/functional/test_coverage.py
|
||||||
|
+++ b/nose2/tests/functional/test_coverage.py
|
||||||
|
@@ -6,6 +6,13 @@ from nose2.tests._common import FunctionalTestCase, support_file
|
||||||
|
|
||||||
|
|
||||||
|
class TestCoverage(FunctionalTestCase):
|
||||||
|
+ def setUp(self):
|
||||||
|
+ super(TestCoverage, self).setUp()
|
||||||
|
+ try:
|
||||||
|
+ import coverage # noqa: F401
|
||||||
|
+ except ImportError:
|
||||||
|
+ self.skipTest("coverage required")
|
||||||
|
+
|
||||||
|
def assertProcOutputPattern(self, proc, libname, stats,
|
||||||
|
total_stats=None, assert_exit_status=0):
|
||||||
|
"""
|
||||||
|
diff --git a/setup.py b/setup.py
|
||||||
|
index 992d2a4..69de6d2 100644
|
||||||
|
--- a/setup.py
|
||||||
|
+++ b/setup.py
|
||||||
|
@@ -28,15 +28,14 @@ setup(
|
||||||
|
],
|
||||||
|
install_requires=[
|
||||||
|
"six>=1.7",
|
||||||
|
- "coverage>=4.4.1",
|
||||||
|
# mock on py2, py3.4 and py3.5
|
||||||
|
# not just py2: py3 versions of mock don't all have the same
|
||||||
|
# interface and this can cause issues
|
||||||
|
'mock==2.0.0;python_version<"3.6"',
|
||||||
|
],
|
||||||
|
extras_require={
|
||||||
|
- "coverage_plugin": ["coverage>=4.4.1"],
|
||||||
|
- "doc": ["Sphinx>=1.6.5", "sphinx_rtd_theme", "mock"],
|
||||||
|
+ "coverage_plugin": ["coverage"],
|
||||||
|
+ "doc": ["Sphinx", "sphinx_rtd_theme", "mock"],
|
||||||
|
},
|
||||||
|
entry_points={
|
||||||
|
"console_scripts": [
|
||||||
|
--
|
||||||
|
2.27.0
|
||||||
|
|
||||||
@ -2,13 +2,15 @@
|
|||||||
|
|
||||||
Name: python-%{srcname}
|
Name: python-%{srcname}
|
||||||
Version: 0.9.2
|
Version: 0.9.2
|
||||||
Release: 1
|
Release: 2
|
||||||
Summary: Next generation of nicer testing for Python
|
Summary: Next generation of nicer testing for Python
|
||||||
|
|
||||||
License: BSD
|
License: BSD
|
||||||
URL: https://nose2.readthedocs.org
|
URL: https://nose2.readthedocs.org
|
||||||
Source0: %pypi_source
|
Source0: %pypi_source
|
||||||
|
|
||||||
|
Patch0: backport-Remove-install_requires-dependency-on-coverage.patch
|
||||||
|
|
||||||
BuildArch: noarch
|
BuildArch: noarch
|
||||||
|
|
||||||
BuildRequires: python%{python3_pkgversion}-devel
|
BuildRequires: python%{python3_pkgversion}-devel
|
||||||
@ -51,7 +53,7 @@ In service of some those goals, some features of nose will not be supported in
|
|||||||
nose2. See the documentation for a thorough rundown.
|
nose2. See the documentation for a thorough rundown.
|
||||||
|
|
||||||
%prep
|
%prep
|
||||||
%autosetup -n %{srcname}-%{version} -p0
|
%autosetup -n %{srcname}-%{version} -p1
|
||||||
|
|
||||||
|
|
||||||
%build
|
%build
|
||||||
@ -74,5 +76,8 @@ PYTHONPATH=`pwd` %{__python3} -m nose2.__main__ -v
|
|||||||
%{_bindir}/nose2
|
%{_bindir}/nose2
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Mon Oct 24 2022 zhangruifang <zhangruifang1@h-partners.com> - 0.9.2-2
|
||||||
|
- delete the require on coverage
|
||||||
|
|
||||||
* Thu Jun 11 2020 Dillon Chen <dillon.chen@turbolinux.com.cn> - 0.9.2-1
|
* Thu Jun 11 2020 Dillon Chen <dillon.chen@turbolinux.com.cn> - 0.9.2-1
|
||||||
- build for openEuler
|
- build for openEuler
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user