%global pypi_name pytest-django Name: python-%{pypi_name} Version: 3.7.0 Release: 1%{?dist} Summary: A Django plugin for pytest License: BSD URL: https://pytest-django.readthedocs.io/ Source0: https://files.pythonhosted.org/packages/source/p/%{pypi_name}/%{pypi_name}-%{version}.tar.gz BuildArch: noarch %description pytest-django allows you to test your Django project/applications with the pytest testing tool. %package -n python3-%{pypi_name} Summary: %{summary} %{?python_provide:%python_provide python3-%{pypi_name}} BuildRequires: python3-devel BuildRequires: python3dist(django) #BuildRequires: python3dist(django-configurations) BuildRequires: python3dist(pathlib2) BuildRequires: python3dist(pytest) BuildRequires: python3dist(setuptools) BuildRequires: python3dist(setuptools-scm) BuildRequires: python3dist(six) BuildRequires: python3dist(sphinx) BuildRequires: python3dist(sphinx-rtd-theme) BuildRequires: python3dist(sphinx) %description -n python3-%{pypi_name} pytest-django allows you to test your Django project/applications with the pytest testing tool. %package -n python-%{pypi_name}-doc Summary: Documentation for %{name} %description -n python-%{pypi_name}-doc Documentation for %{name}. %prep %autosetup -n %{pypi_name}-%{version} # Remove bundled egg-info rm -rf %{pypi_name}.egg-info %build %py3_build # Generate HTML docs PYTHONPATH=${PWD} sphinx-build-3 docs html # Remove the sphinx-build leftovers rm -rf html/.{doctrees,buildinfo} %install %py3_install # Tests require a Django project that is set up. This doesn't seems to be possible # on the build system #%check #PYTHONPATH=%{buildroot}%{python3_sitelib} pytest-%{python3_version} -v %files -n python3-%{pypi_name} %license LICENSE %doc README.rst %{python3_sitelib}/pytest_django %{python3_sitelib}/pytest_django-%{version}-py?.?.egg-info %files -n python-%{pypi_name}-doc %doc html %license LICENSE %changelog * Sat Dec 28 2019 Fabian Affolter - 3.7.0-1 - Initial package for Fedora