From 50f2e8f3e90d6ac148c95ecaa868df2fa8ca1f924af1dac87ec5c816d65dec7b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mark=C3=A9ta=20Machov=C3=A1?= Date: Fri, 18 Dec 2020 09:59:38 +0000 Subject: [PATCH] Accepting request 856730 from home:bnavigator:branches:devel:languages:python - Do not require and test with pook on Python2 We will need something like a python3_module macro available to the OBS resolver in order to make stuff like this easier OBS-URL: https://build.opensuse.org/request/show/856730 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-mocket?expand=0&rev=21 --- python-mocket.changes | 5 +++++ python-mocket.spec | 7 ++++++- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/python-mocket.changes b/python-mocket.changes index 9f7f811..f60ea3a 100644 --- a/python-mocket.changes +++ b/python-mocket.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Thu Dec 17 17:09:52 UTC 2020 - Benjamin Greiner + +- Do not require and test with pook on Python2 + ------------------------------------------------------------------- Thu Dec 17 15:10:50 UTC 2020 - Benjamin Greiner diff --git a/python-mocket.spec b/python-mocket.spec index 203bcd8..117d05c 100644 --- a/python-mocket.spec +++ b/python-mocket.spec @@ -53,7 +53,12 @@ BuildRequires: %{python_module decorator} BuildRequires: %{python_module gevent} BuildRequires: %{python_module http-parser >= 0.9.0} BuildRequires: %{python_module mock} +%if 0%{suse_version} >= 1550 +# Optional pook is only available for Python 3, but in TW we will have more than one flavor BuildRequires: %{python_module pook} +%else +BuildRequires: python3-pook +%endif BuildRequires: %{python_module pyOpenSSL} BuildRequires: %{python_module pytest} BuildRequires: %{python_module python-magic} @@ -96,7 +101,7 @@ export LANG=en_US.UTF-8 %if %{with test} export LANG=en_US.UTF-8 export SKIP_TRUE_HTTP=1 -pytest_python2_ignore="--ignore tests/tests35 --ignore tests/tests38" +pytest_python2_ignore="--ignore tests/tests35 --ignore tests/tests38 --ignore tests/main/test_pook.py" pytest_python36_ignore="--ignore tests/tests38" %if %{python3_version_nodots} < 38 pytest_python3_ignore="--ignore tests/tests38"