]> git.pld-linux.org Git - packages/python3-pytest-asyncio.git/blame - python3-pytest-asyncio.spec
- updated to 0.19.0
[packages/python3-pytest-asyncio.git] / python3-pytest-asyncio.spec
CommitLineData
bda4c6eb
JB
1#
2# Conditional build:
639e9c9b 3%bcond_without tests # unit tests
bda4c6eb
JB
4
5Summary: Pytest support for asyncio
6Summary(pl.UTF-8): Wsparcie do asyncio dla Pytesta
7Name: python3-pytest-asyncio
0663110e
JB
8Version: 0.19.0
9Release: 1
bda4c6eb
JB
10License: Apache v2.0
11Group: Libraries/Python
12#Source0Download: https://pypi.org/simple/pytest-asyncio/
13Source0: https://files.pythonhosted.org/packages/source/p/pytest-asyncio/pytest-asyncio-%{version}.tar.gz
0663110e 14# Source0-md5: 0c74a0ae2b509735594684bf00512252
bda4c6eb 15URL: https://pypi.org/project/pytest-asyncio/
639e9c9b 16BuildRequires: python3-modules >= 1:3.7
0663110e
JB
17BuildRequires: python3-setuptools >= 1:51.0
18#BuildRequires: python3-setuptools_scm >= 6.2
19BuildRequires: python3-toml
bda4c6eb 20%if %{with tests}
639e9c9b 21BuildRequires: python3-flaky >= 3.5.0
bda4c6eb 22BuildRequires: python3-hypothesis >= 5.7.1
639e9c9b 23BuildRequires: python3-pytest >= 6.1.0
0663110e
JB
24BuildRequires: python3-pytest-trio
25%if "%{py3_ver}" == "3.7"
639e9c9b
JB
26BuildRequires: python3-typing_extensions >= 3.7.2
27%endif
bda4c6eb
JB
28%endif
29BuildRequires: rpm-pythonprov
30BuildRequires: rpmbuild(macros) >= 1.714
639e9c9b 31Requires: python3-modules >= 1:3.7
bda4c6eb
JB
32BuildArch: noarch
33BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
34
35%description
36pytest-asyncio is an Apache 2 licensed library, written in Python, for
37testing asyncio code with pytest.
38
39asyncio code is usually written in the form of coroutines, which makes
40it slightly more difficult to test using normal testing tools.
41pytest-asyncio provides useful fixtures and markers to make testing
42easier.
43
44%description -l pl.UTF-8
45pytest-asyncio to wydana na licencji Apache 2 biblioteka, napisana w
46Pythonie, służąca do testowania kodu asynchronicznego we/wy przy
47użyciu pytesta.
48
49Kod asyncio jest zwykle pisany w postaci korutyn, co nieco utrudnia
50testowanie przy użyciu zwykłych narzędzi testowych. pytest-asyncio
51dostarcza przydatne wyposażenie i znaczniki ułatwiające testowanie.
52
53%prep
54%setup -q -n pytest-asyncio-%{version}
55
0663110e
JB
56# stub for setuptools
57cat >setup.py <<EOF
58from setuptools import setup
59setup()
60EOF
61
bda4c6eb
JB
62%build
63%py3_build
64
65%if %{with tests}
639e9c9b
JB
66# test_flaky_integration failure: no expected report found
67# test_legacy_mode failures: more warnings than expected
68PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 \
0663110e 69PYTEST_PLUGINS="pytest_asyncio.plugin,pytest_trio.plugin" \
639e9c9b
JB
70PYTHONPATH=$(pwd) \
71%{__python3} -m pytest tests -k 'not test_flaky_integration and not test_legacy_mode'
bda4c6eb
JB
72%endif
73
74%install
75rm -rf $RPM_BUILD_ROOT
76
77%py3_install
78
79%clean
80rm -rf $RPM_BUILD_ROOT
81
82%files
83%defattr(644,root,root,755)
0663110e 84%doc CHANGELOG.rst README.rst
bda4c6eb
JB
85%{py3_sitescriptdir}/pytest_asyncio
86%{py3_sitescriptdir}/pytest_asyncio-%{version}-py*.egg-info
This page took 0.167768 seconds and 4 git commands to generate.