[packages/python3-flaky] Up to 3.8.1
arekm
arekm at pld-linux.org
Sat Feb 8 15:50:16 CET 2025
commit 2540500adf822d1677669987f08bb4c6018b42a7
Author: Arkadiusz Miśkiewicz <arekm at maven.pl>
Date: Sat Feb 8 15:10:49 2025 +0100
Up to 3.8.1
python-flaky-mock.patch | 32 ------------
python-flaky.spec | 136 ------------------------------------------------
python3-flaky.spec | 68 ++++++++++++++++++++++++
3 files changed, 68 insertions(+), 168 deletions(-)
---
diff --git a/python-flaky.spec b/python-flaky.spec
deleted file mode 100644
index 573c357..0000000
--- a/python-flaky.spec
+++ /dev/null
@@ -1,136 +0,0 @@
-#
-# Conditional build:
-%bcond_with tests # unit tests (many failures)
-%bcond_without python2 # CPython 2.x module
-%bcond_without python3 # CPython 3.x module
-
-Summary: Plugin for nose or pytest that automatically reruns flaky tests
-Summary(pl.UTF-8): Wtyczka dla nose lub pytesta automatycznie uruchamiająca ponownie niepewne testy
-Name: python-flaky
-Version: 3.7.0
-Release: 1
-License: Apache v2.0
-Group: Libraries/Python
-#Source0Download: https://pypi.org/simple/flaky/
-Source0: https://files.pythonhosted.org/packages/source/f/flaky/flaky-%{version}.tar.gz
-# Source0-md5: 1dbc0f9f356d922f2a3004ee1f05993e
-Patch0: %{name}-mock.patch
-URL: https://pypi.org/project/flaky/
-%if %{with python2}
-BuildRequires: python-modules >= 1:2.7
-BuildRequires: python-setuptools
-%if %{with tests}
-BuildRequires: python-genty
-BuildRequires: python-mock
-BuildRequires: python-pytest
-%endif
-%endif
-%if %{with python3}
-BuildRequires: python3-modules >= 1:3.4
-BuildRequires: python3-setuptools
-%if %{with tests}
-BuildRequires: python3-genty
-BuildRequires: python3-pytest
-%endif
-%endif
-BuildRequires: rpm-pythonprov
-BuildRequires: rpmbuild(macros) >= 1.714
-Requires: python-modules >= 1:2.7
-BuildArch: noarch
-BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
-
-%description
-Flaky is a plugin for nose or pytest that automatically reruns flaky
-tests.
-
-Ideally, tests reliably pass or fail, but sometimes test fixtures must
-rely on components that aren't 100% reliable. With flaky, instead of
-removing those tests or marking them to @skip, they can be
-automatically retried.
-
-%description -l pl.UTF-8
-Flaky to wtyczka dla nose lub pytesta automatycznie uruchamiająca
-ponownie niepewne testy.
-
-Idealnie testy powinny deterministycznie powodzić się lub nie, ale
-czasem wypozażenia testów muszą polegać na komponentach nie w pełni
-deterministycznych. Przy pomocy modułu flaky, zamiast usuwania tych
-testów lub oznaczania ich @skip, można je automatycznie ponowić.
-
-%package -n python3-flaky
-Summary: Plugin for nose or pytest that automatically reruns flaky tests
-Summary(pl.UTF-8): Wtyczka dla nose lub pytesta automatycznie uruchamiająca ponownie niepewne testy
-Group: Libraries/Python
-Requires: python3-modules >= 1:3.4
-
-%description -n python3-flaky
-Flaky is a plugin for nose or pytest that automatically reruns flaky
-tests.
-
-Ideally, tests reliably pass or fail, but sometimes test fixtures must
-rely on components that aren't 100% reliable. With flaky, instead of
-removing those tests or marking them to @skip, they can be
-automatically retried.
-
-%description -n python3-flaky -l pl.UTF-8
-Flaky to wtyczka dla nose lub pytesta automatycznie uruchamiająca
-ponownie niepewne testy.
-
-Idealnie testy powinny deterministycznie powodzić się lub nie, ale
-czasem wypozażenia testów muszą polegać na komponentach nie w pełni
-deterministycznych. Przy pomocy modułu flaky, zamiast usuwania tych
-testów lub oznaczania ich @skip, można je automatycznie ponowić.
-
-%prep
-%setup -q -n flaky-%{version}
-%patch0 -p1
-
-%build
-%if %{with python2}
-%py_build
-
-%if %{with tests}
-LC_ALL=C.UTF-8 \
-%{__python} -m unittest discover -s test
-%endif
-%endif
-
-%if %{with python3}
-%py3_build
-
-%if %{with tests}
-%{__python3} -m unittest discover -s test
-%endif
-%endif
-
-%install
-rm -rf $RPM_BUILD_ROOT
-
-%if %{with python2}
-%py_install
-
-%py_postclean
-%endif
-
-%if %{with python3}
-%py3_install
-%endif
-
-%clean
-rm -rf $RPM_BUILD_ROOT
-
-%if %{with python2}
-%files
-%defattr(644,root,root,755)
-%doc README.rst
-%{py_sitescriptdir}/flaky
-%{py_sitescriptdir}/flaky-%{version}-py*.egg-info
-%endif
-
-%if %{with python3}
-%files -n python3-flaky
-%defattr(644,root,root,755)
-%doc README.rst
-%{py3_sitescriptdir}/flaky
-%{py3_sitescriptdir}/flaky-%{version}-py*.egg-info
-%endif
diff --git a/python3-flaky.spec b/python3-flaky.spec
new file mode 100644
index 0000000..0e65854
--- /dev/null
+++ b/python3-flaky.spec
@@ -0,0 +1,68 @@
+#
+# Conditional build:
+%bcond_with tests # unit tests (many failures)
+
+Summary: Plugin for nose or pytest that automatically reruns flaky tests
+Summary(pl.UTF-8): Wtyczka dla nose lub pytesta automatycznie uruchamiająca ponownie niepewne testy
+Name: python3-flaky
+Version: 3.8.1
+Release: 1
+License: Apache v2.0
+Group: Libraries/Python
+#Source0Download: https://pypi.org/simple/flaky/
+Source0: https://files.pythonhosted.org/packages/source/f/flaky/flaky-%{version}.tar.gz
+# Source0-md5: 59d67ca4439d37936fb7368c140d23e7
+URL: https://pypi.org/project/flaky/
+BuildRequires: python3-modules >= 1:3.4
+BuildRequires: python3-setuptools
+%if %{with tests}
+BuildRequires: python3-genty
+BuildRequires: python3-pytest
+%endif
+BuildRequires: rpm-pythonprov
+BuildRequires: rpmbuild(macros) >= 1.714
+Requires: python3-modules >= 1:3.5
+BuildArch: noarch
+BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
+
+%description
+Flaky is a plugin for nose or pytest that automatically reruns flaky
+tests.
+
+Ideally, tests reliably pass or fail, but sometimes test fixtures must
+rely on components that aren't 100% reliable. With flaky, instead of
+removing those tests or marking them to @skip, they can be
+automatically retried.
+
+%description -l pl.UTF-8
+Flaky to wtyczka dla nose lub pytesta automatycznie uruchamiająca
+ponownie niepewne testy.
+
+Idealnie testy powinny deterministycznie powodzić się lub nie, ale
+czasem wypozażenia testów muszą polegać na komponentach nie w pełni
+deterministycznych. Przy pomocy modułu flaky, zamiast usuwania tych
+testów lub oznaczania ich @skip, można je automatycznie ponowić.
+
+%prep
+%setup -q -n flaky-%{version}
+
+%build
+%py3_build
+
+%if %{with tests}
+%{__python3} -m unittest discover -s test
+%endif
+
+%install
+rm -rf $RPM_BUILD_ROOT
+
+%py3_install
+
+%clean
+rm -rf $RPM_BUILD_ROOT
+
+%files
+%defattr(644,root,root,755)
+%doc README.rst
+%{py3_sitescriptdir}/flaky
+%{py3_sitescriptdir}/flaky-%{version}-py*.egg-info
diff --git a/python-flaky-mock.patch b/python-flaky-mock.patch
deleted file mode 100644
index 5ed31d7..0000000
--- a/python-flaky-mock.patch
+++ /dev/null
@@ -1,32 +0,0 @@
---- flaky-3.6.1/test/test_nose/test_flaky_nose_plugin.py.orig 2019-01-09 18:29:18.000000000 +0100
-+++ flaky-3.6.1/test/test_nose/test_flaky_nose_plugin.py 2020-01-13 16:06:51.602083798 +0100
-@@ -5,8 +5,12 @@
- from unittest import TestCase
-
- from genty import genty, genty_dataset
--import mock
--from mock import MagicMock, Mock, patch
-+try:
-+ import mock
-+ from mock import MagicMock, Mock, patch
-+except ImportError:
-+ from unittest import mock
-+ from unittest.mock import MagicMock, Mock, patch
-
- from flaky import defaults, flaky_nose_plugin
- from flaky.flaky_decorator import flaky
---- flaky-3.6.1/test/test_pytest/test_flaky_pytest_plugin.py.orig 2019-08-06 20:25:51.000000000 +0200
-+++ flaky-3.6.1/test/test_pytest/test_flaky_pytest_plugin.py 2020-01-13 16:07:18.311939098 +0100
-@@ -2,7 +2,11 @@
-
- from __future__ import unicode_literals
- from io import StringIO
--from mock import Mock, patch
-+try:
-+ from mock import Mock, patch
-+except ImportError:
-+ from unittest.mock import Mock, patch
-+
- # pylint:disable=import-error
- import pytest
- from _pytest.runner import CallInfo
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/python3-flaky.git/commitdiff/2540500adf822d1677669987f08bb4c6018b42a7
More information about the pld-cvs-commit
mailing list