summaryrefslogtreecommitdiffstats
path: root/komikku/python-polling.spec
blob: b501034c51eae9533e1f888e9c6ea18dc65e20c1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
%global shortname polling

Name:           python-%{shortname}
Version:        0.3.0
Release:        1%{?dist}
Summary:        Powerful polling utility in Python

License:        MIT
URL:            https://github.com/justiniso/%{shortname}
Source0:        %{url}/archive/v%{version}/%{shortname}-%{version}.tar.gz

BuildArch:      noarch

%global _description %{expand:
Polling is a powerful python utility used to wait for a function to return a certain expected condition. Some possible uses cases include:

- Wait for API response to return with code 200
- Wait for a file to exist (or not exist)
- Wait for a thread lock on a resource to expire
}

%description    %{_description}

%package        -n python3-%{shortname}
Summary:        %{Summary}
BuildRequires:  python3-devel
BuildRequires:  python3-mock
BuildRequires:  python3-pytest
%{?python_provide:%python_provide python3-%{shortname}}

%description    -n python3-%{shortname} %{_description}

%prep
%autosetup      -n %{shortname}-%{version}

%build
%py3_build

%install
%py3_install

%check
py.test tests

%files          -n python3-%{shortname}
%license LICENSE.md
%doc README.md
%pycached %{python3_sitelib}/%{shortname}.py
%{python3_sitelib}/%{shortname}-%{version}-py*.egg-info

%changelog
* Sun Mar 29 2020 Lyes Saadi <fedora@lyes.eu> - 0.3.0-1
- Initial package.