Blame python-pytest-lazy-fixture.spec

f5bf0e5
# Enabled by default
f5bf0e5
%bcond_with tests
f5bf0e5
f5bf0e5
%global pypi_name pytest-lazy-fixture
f5bf0e5
f5bf0e5
%global _description %{expand:
f5bf0e5
Use fixtures in pytest.mark.parametrize.}
f5bf0e5
f5bf0e5
Name:           python-%{pypi_name}
f5bf0e5
Version:        0.5.2
f5bf0e5
Release:        1%{?dist}
f5bf0e5
Summary:        Use fixtures in pytest.mark.parametrize
f5bf0e5
f5bf0e5
# https://fedoraproject.org/wiki/Licensing:Main?rd=Licensing#Good_Licenses
f5bf0e5
License:        MIT
f5bf0e5
URL:            https://pypi.python.org/pypi/%{pypi_name}
f5bf0e5
Source0:        %pypi_source %{pypi_name}
f5bf0e5
f5bf0e5
BuildArch:      noarch
f5bf0e5
f5bf0e5
%{?python_enable_dependency_generator}
f5bf0e5
f5bf0e5
%description %_description
f5bf0e5
f5bf0e5
%package -n python3-%{pypi_name}
f5bf0e5
Summary:        %{summary}
f5bf0e5
BuildRequires:  python3-devel
f5bf0e5
BuildRequires:  %{py3_dist pytest}
f5bf0e5
f5bf0e5
%{?python_provide:%python_provide python3-%{pypi_name}}
f5bf0e5
f5bf0e5
%description -n python3-%{pypi_name} %_description
f5bf0e5
f5bf0e5
%prep
f5bf0e5
%autosetup -n %{pypi_name}-%{version}
f5bf0e5
rm -rf %{pypi_name}.egg-info
f5bf0e5
f5bf0e5
# Comment out to remove /usr/bin/env shebangs
f5bf0e5
# Can use something similar to correct/remove /usr/bin/python shebangs also
f5bf0e5
# find . -type f -name "*.py" -exec sed -i '/^#![  ]*\/usr\/bin\/env.*$/ d' {} 2>/dev/null ';'
f5bf0e5
f5bf0e5
%build
f5bf0e5
%py3_build
f5bf0e5
f5bf0e5
%install
f5bf0e5
%py3_install
f5bf0e5
f5bf0e5
%check
f5bf0e5
%if %{with tests}
f5bf0e5
PYTHONPATH="%{buildroot}/%{python3_sitelib}/" pytest-3
f5bf0e5
%endif
f5bf0e5
f5bf0e5
%files -n python3-%{pypi_name}
f5bf0e5
%license LICENSE
f5bf0e5
%doc README.rst
f5bf0e5
%{python3_sitelib}/pytest_lazy_fixture-%{version}-py%{python3_version}.egg-info
f5bf0e5
%{python3_sitelib}/pytest_lazyfixture.py
f5bf0e5
%{python3_sitelib}/__pycache__
f5bf0e5
f5bf0e5
%changelog
f5bf0e5
* Fri Jul 12 2019 Ankur Sinha <ankursinha AT fedoraproject DOT org> - 0.5.2-1
f5bf0e5
- Own pycache directory to fix permission issues #1723047
f5bf0e5
f5bf0e5
* Sat Jun 22 2019 Ankur Sinha <ankursinha AT fedoraproject DOT org> - 0.5.2-1
f5bf0e5
- Initial package