From fe568e222ca9f2979df2e77ff13d9fc3b896a9c3a94fed391adcc1b24b81309e Mon Sep 17 00:00:00 2001 From: Tomas Cech Date: Fri, 9 Feb 2018 14:53:26 +0000 Subject: [PATCH] - put LICENSE with %license - make conditional tests (but disable by default because of OBS build isolation) OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-aiodns?expand=0&rev=2 --- python-aiodns.changes | 7 +++++++ python-aiodns.spec | 22 ++++++++++++++++++---- 2 files changed, 25 insertions(+), 4 deletions(-) diff --git a/python-aiodns.changes b/python-aiodns.changes index 6dc65a6..3750bf6 100644 --- a/python-aiodns.changes +++ b/python-aiodns.changes @@ -1,3 +1,10 @@ +------------------------------------------------------------------- +Fri Feb 9 14:52:05 UTC 2018 - sleep_walker@opensuse.org + +- put LICENSE with %license +- make conditional tests (but disable by default because of OBS build + isolation) + ------------------------------------------------------------------- Fri Feb 9 13:16:39 UTC 2018 - sleep_walker@opensuse.org diff --git a/python-aiodns.spec b/python-aiodns.spec index ec08e62..4b1d5c6 100644 --- a/python-aiodns.spec +++ b/python-aiodns.spec @@ -16,17 +16,24 @@ # +# DNS tests won't work in OBS +%bcond_with tests + Name: python-aiodns Version: 1.1.1 Release: 0 Summary: Simple DNS resolver for asyncio License: MIT Group: Development/Libraries/Python -URL: https://github.com/saghul/aiodns/releases +Url: https://github.com/saghul/aiodns/releases Source0: https://github.com/saghul/aiodns/archive/aiodns-%{version}.tar.gz -BuildRequires: python-rpm-macros -BuildRequires: %{python_module devel} +BuildRequires: %{python_module setuptools} BuildRequires: fdupes +BuildRequires: python-rpm-macros +%if %{with tests} +BuildRequires: python-pycares +BuildRequires: python-trollius +%endif BuildArch: noarch %python_subpackages @@ -44,7 +51,14 @@ Simple DNS resolver for asyncio module. %python_install %python_expand %fdupes %{buildroot}%{$python_sitelib}/aiodns/ +%if %{with tests} +%check +%python_exec ./tests.py +%endif %files %{python_files} -%doc LICENSE ChangeLog README.rst +%doc ChangeLog README.rst +%license LICENSE %{python_sitelib}/aiodns* + +%changelog