From 3643bbb0740c836fa3f070aa375019e17aaebb080c657035bbadb5bc356120cc Mon Sep 17 00:00:00 2001 From: Steve Kowalik Date: Tue, 7 May 2024 03:12:59 +0000 Subject: [PATCH] - Switch to pyproject macros. - Skip some tests that have been broken by pytest 8.2. OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:pytest/python-pytest-rerunfailures?expand=0&rev=27 --- python-pytest-rerunfailures.changes | 6 ++++++ python-pytest-rerunfailures.spec | 22 +++++++++++++++------- 2 files changed, 21 insertions(+), 7 deletions(-) diff --git a/python-pytest-rerunfailures.changes b/python-pytest-rerunfailures.changes index 4264629..4063a82 100644 --- a/python-pytest-rerunfailures.changes +++ b/python-pytest-rerunfailures.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Tue May 7 03:12:25 UTC 2024 - Steve Kowalik + +- Switch to pyproject macros. +- Skip some tests that have been broken by pytest 8.2. + ------------------------------------------------------------------- Sat Mar 16 09:48:54 UTC 2024 - Dirk Müller diff --git a/python-pytest-rerunfailures.spec b/python-pytest-rerunfailures.spec index 4c6f040..ff7ba8f 100644 --- a/python-pytest-rerunfailures.spec +++ b/python-pytest-rerunfailures.spec @@ -25,11 +25,13 @@ License: MPL-2.0 URL: https://github.com/pytest-dev/pytest-rerunfailures Source: https://files.pythonhosted.org/packages/source/p/pytest-rerunfailures/pytest-rerunfailures-%{version}.tar.gz BuildRequires: %{python_module base >= 3.7} +BuildRequires: %{python_module pip} BuildRequires: %{python_module setuptools >= 40.0} +BuildRequires: %{python_module wheel} BuildRequires: fdupes BuildRequires: python-rpm-macros +Requires: python-packaging >= 17.1 Requires: python-pytest >= 7.2 -Requires: python-setuptools >= 40.0 BuildArch: noarch # SECTION test requirements BuildRequires: %{python_module pytest >= 7.2} @@ -45,20 +47,26 @@ tests to eliminate intermittent failures. %setup -q -n pytest-rerunfailures-%{version} %build -%python_build +%pyproject_wheel %install -%python_install +%pyproject_install %python_expand %fdupes %{buildroot}%{$python_sitelib} %check -%pytest +# https://github.com/pytest-dev/pytest-rerunfailures/issues/267 +donttest="test_run_session_teardown_once_after_reruns " +donttest+="or test_exception_matches_rerun_except_query " +donttest+="or test_exception_not_match_rerun_except_query " +donttest+="or test_exception_matches_only_rerun_query " +donttest+="or test_exception_match_only_rerun_in_dual_query" +%pytest -k "not (${donttest})" %files %{python_files} %doc CHANGES.rst README.rst %license LICENSE -%{python_sitelib}/pytest_rerunfailures.py* -%pycache_only %{python_sitelib}/__pycache__/pytest_rerunfailures* -%{python_sitelib}/pytest_rerunfailures-%{version}*-info +%{python_sitelib}/pytest_rerunfailures.py +%pycache_only %{python_sitelib}/__pycache__/pytest_rerunfailures*pyc +%{python_sitelib}/pytest_rerunfailures-%{version}.dist-info %changelog