forked from pool/python-pytest-randomly
Accepting request 688847 from home:jayvdb:branches:devel:languages:python:pytest
- Downgrade Faker dependency to Recommends
- Add Suggests for numpy
- Add tests-restore-python2.7.patch to re-add support for Python 2.7
- Use PYTHONDONTWRITEBYTECODE=true to fix file-contains-buildroot
on Leap 42.3
- Update to v2.1.1
* Fix including tests in sdist after re-arrangement in 2.1.0
- from v2.1.0
* Add the option --randomly-seed=last to reuse the last used value
for the seed
- from v2.0.0
* Drop Python 2 support, only Python 3.4+ is supported now
- Make sure we execute tests
- Initial version for v1.2.3
OBS-URL: https://build.opensuse.org/request/show/688847
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:pytest/python-pytest-randomly?expand=0&rev=5
This commit is contained in:
@@ -18,24 +18,28 @@
|
||||
|
||||
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
|
||||
Name: python-pytest-randomly
|
||||
Version: 1.2.3
|
||||
Version: 2.1.1
|
||||
Release: 0
|
||||
Summary: Pytest plugin to randomly order tests and control random.seed
|
||||
License: BSD-3-Clause
|
||||
Group: Development/Languages/Python
|
||||
URL: https://github.com/adamchainz/pytest-randomly
|
||||
Source: https://files.pythonhosted.org/packages/source/p/pytest-randomly/pytest-randomly-%{version}.tar.gz
|
||||
# Reverse of https://github.com/pytest-dev/pytest-randomly/commit/7ca48ad.patch
|
||||
Patch0: tests-restore-python2.7.patch
|
||||
BuildRequires: %{python_module setuptools}
|
||||
BuildRequires: fdupes
|
||||
BuildRequires: python-rpm-macros
|
||||
Requires: python-Faker
|
||||
Requires: python-pytest
|
||||
Recommends: python-Faker
|
||||
Suggests: python-numpy
|
||||
BuildArch: noarch
|
||||
# SECTION test requirements
|
||||
BuildRequires: %{python_module Faker}
|
||||
BuildRequires: %{python_module factory_boy}
|
||||
BuildRequires: %{python_module numpy}
|
||||
BuildRequires: %{python_module pytest}
|
||||
BuildRequires: %{python_module six}
|
||||
# /SECTION
|
||||
%python_subpackages
|
||||
|
||||
@@ -61,6 +65,9 @@ Features:
|
||||
|
||||
%prep
|
||||
%setup -q -n pytest-randomly-%{version}
|
||||
%patch0 -p1
|
||||
# Disregard Python 3.4+ restriction
|
||||
sed -i '/python_requires/d' setup.py
|
||||
|
||||
%build
|
||||
%python_build
|
||||
@@ -70,6 +77,7 @@ Features:
|
||||
%python_expand %fdupes %{buildroot}%{$python_sitelib}
|
||||
|
||||
%check
|
||||
export PYTHONDONTWRITEBYTECODE=true
|
||||
%python_expand PYTHONPATH=%{buildroot}%{$python_sitelib} py.test-%{$python_bin_suffix} -v
|
||||
|
||||
%files %{python_files}
|
||||
|
||||
Reference in New Issue
Block a user