3 %bcond_with tests # unit tests (missing .util in test/server.py?)
4 %bcond_without python2 # CPython 2.x module
5 %bcond_without python3 # CPython 3.x module
7 Summary: Server to test HTTP clients
8 Summary(pl.UTF-8): Serwer do testówania klientów HTTP
9 Name: python-test-server
13 Group: Libraries/Python
14 #Source0Download: https://pypi.org/simple/test-server/
15 Source0: https://files.pythonhosted.org/packages/source/t/test-server/test-server-%{version}.tar.gz
16 # Source0-md5: 61afb28c2d3455f618f5bfa27bc54153
17 URL: https://pypi.org/project/test-server/
19 BuildRequires: python-modules >= 1:2.7
20 BuildRequires: python-setuptools
22 BuildRequires: python-bottle >= 0.12.13
23 BuildRequires: python-pytest
24 BuildRequires: python-six
25 BuildRequires: python-webtest
29 BuildRequires: python3-modules >= 1:3.3
30 BuildRequires: python3-setuptools
32 BuildRequires: python3-bottle >= 0.12.13
33 BuildRequires: python3-pytest
34 BuildRequires: python3-six
35 BuildRequires: python3-webtest
38 BuildRequires: rpm-pythonprov
39 BuildRequires: rpmbuild(macros) >= 1.714
40 Requires: python-modules >= 1:2.7
42 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
45 HTTP Server to test HTTP clients.
47 %description -l pl.UTF-8
48 Serwer HTTP do testowania klientów HTTP.
50 %package -n python3-test-server
51 Summary: Server to test HTTP clients
52 Summary(pl.UTF-8): Serwer do testówania klientów HTTP
53 Group: Libraries/Python
54 Requires: python3-modules >= 1:3.3
56 %description -n python3-test-server
57 HTTP Server to test HTTP clients.
59 %description -n python3-test-server -l pl.UTF-8
60 Serwer HTTP do testowania klientów HTTP.
63 %setup -q -n test-server-%{version}
78 %{__python3} -m pytest
83 rm -rf $RPM_BUILD_ROOT
96 rm -rf $RPM_BUILD_ROOT
100 %defattr(644,root,root,755)
101 %doc CHANGELOG.md README.rst
102 %{py_sitescriptdir}/test_server
103 %{py_sitescriptdir}/test_server-%{version}-py*.egg-info
107 %files -n python3-test-server
108 %defattr(644,root,root,755)
109 %doc CHANGELOG.md README.rst
110 %{py3_sitescriptdir}/test_server
111 %{py3_sitescriptdir}/test_server-%{version}-py*.egg-info