diff --git a/python-jmespath.spec b/python-jmespath.spec index 7a30574..c171101 100644 --- a/python-jmespath.spec +++ b/python-jmespath.spec @@ -1,6 +1,6 @@ Name: python-jmespath Version: 0.10.0 -Release: 1 +Release: 2 Summary: Matching Expressions for JSON License: MIT URL: https://github.com/jmespath/jmespath.py @@ -15,7 +15,7 @@ extract elements from a JSON document. Summary: JSON Matching Expressions %{?python_provide:%python_provide python3-jmespath} -BuildRequires: python3-devel python3-mock python3-nose python3-setuptools +BuildRequires: python3-devel python3-mock python3-setuptools %description -n python3-jmespath JMESPath is a python library which allows you to declaratively specify how to @@ -35,7 +35,7 @@ mv %{buildroot}/%{_bindir}/jp.py %{buildroot}/%{_bindir}/jp.py-%{python3_version ln -sf %{_bindir}/jp.py-%{python3_version} %{buildroot}/%{_bindir}/jp.py-3 %check -nosetests-%{python3_version} +python3 -m unittest discover -v %files -n python3-jmespath %doc README.rst LICENSE.txt @@ -44,6 +44,9 @@ nosetests-%{python3_version} %{python3_sitelib}/jmespath* %changelog +* Fri Apr 29 2022 houyingchao - 0.10.0-2 +- Remove dependency on python-nose + * Wed Jul 14 2021 huangtianhua - 0.10.0-1 - Upgrade to 0.10.0 to support OpenStack-W diff --git a/remove-nose.patch b/remove-nose.patch new file mode 100644 index 0000000..ab2f35a --- /dev/null +++ b/remove-nose.patch @@ -0,0 +1,34 @@ +Index: jmespath.py-0.10.0/extra/test_hypothesis.py +=================================================================== +--- jmespath.py-0.10.0.orig/extra/test_hypothesis.py ++++ jmespath.py-0.10.0/extra/test_hypothesis.py +@@ -6,7 +6,6 @@ import os + import sys + import numbers + +-from nose.plugins.skip import SkipTest + from hypothesis import given, settings, assume, HealthCheck + import hypothesis.strategies as st + +Index: jmespath.py-0.10.0/tests/test_compliance.py +=================================================================== +--- jmespath.py-0.10.0.orig/tests/test_compliance.py ++++ jmespath.py-0.10.0/tests/test_compliance.py +@@ -3,8 +3,6 @@ from pprint import pformat + from tests import OrderedDict + from tests import json + +-from nose.tools import assert_equal +- + from jmespath.visitor import Options + + +@@ -80,7 +78,7 @@ def _test_expression(given, expression, + actual_repr, pformat(parsed.parsed), + json.dumps(given, indent=4))) + error_msg = error_msg.replace(r'\n', '\n') +- assert_equal(actual, expected, error_msg) ++ assert actual == expected, error_msg + + + def _test_error_expression(given, expression, error, filename):