python-httmock/python-httmock.spec

64 lines
1.7 KiB
RPMSpec
Raw Normal View History

2020-12-16 20:16:23 +08:00
%{?python_enable_dependency_generator}
# Created by pyp2rpm-3.3.0
%global pypi_name httmock
Name: python-%{pypi_name}
2022-06-14 09:14:37 +08:00
Version: 1.4.0
Release: 1
2020-12-16 20:16:23 +08:00
Summary: A mocking library for requests
License: ASL 2.0
URL: https://github.com/patrys/httmock
2022-06-14 09:14:37 +08:00
Source0: https://github.com/patrys/httmock/archive/refs/tags/%{version}.tar.gz
2020-12-16 20:16:23 +08:00
Source1: https://raw.githubusercontent.com/patrys/httmock/%{version}/tests.py
BuildArch: noarch
%description
A mocking library for requests for Python.
You can use it to mock third-party APIs and test libraries
that use requests internally.
%package -n python3-%{pypi_name}
Summary: %{summary}
%{?python_provide:%python_provide python3-%{pypi_name}}
BuildRequires: python3-devel
BuildRequires: python3-setuptools
BuildRequires: python3dist(requests) >= 1
%description -n python3-%{pypi_name}
A mocking library for requests for Python.
You can use it to mock third-party APIs and test libraries
that use requests internally.
%prep
%autosetup -n %{pypi_name}-%{version}
# Remove bundled egg-info
rm -rf %{pypi_name}.egg-info
cp %{SOURCE1} .
%build
%py3_build
%install
%py3_install
%check
%{__python3} setup.py test
%files -n python3-%{pypi_name}
%license LICENSE
%doc README.md
%{python3_sitelib}/__pycache__/*
%{python3_sitelib}/%{pypi_name}.py
2022-03-31 15:20:08 +08:00
%{python3_sitelib}/%{pypi_name}-%{version}-py%{python3_version}.egg-info
2020-12-16 20:16:23 +08:00
%changelog
2022-06-14 09:14:37 +08:00
* Tue Jun 14 2022 xigaoxinyan <xigaoxinyanA@h-partners.com> - 1.4.0-1
- Update to 1.4.0
2022-03-31 15:20:08 +08:00
* Thu Mar 31 2022 xigaoxinyan <xigaoxinyan@huawei.com> - 1.3.0-2
2022-06-14 09:14:37 +08:00
- Fix build error caused by py3.10+ wildcard
2022-03-31 15:20:08 +08:00
2020-12-16 20:16:23 +08:00
* Thu Dec 17 2020 jiangxinyu <jiangxinyu@kylinos.cn> - 1.3.0-1
- Init httmock project