From 2fbc3ab63d8b99dcd92a6204346e85340f287c96d9067ff3e4170be18c307b4b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Chv=C3=A1tal?= Date: Tue, 11 Aug 2020 07:08:33 +0000 Subject: [PATCH 1/2] - Switch to multibuild as we create cycle with python-pook otherwise OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-mocket?expand=0&rev=11 --- python-mocket.changes | 5 +++++ python-mocket.spec | 21 +++++++++++++++++---- 2 files changed, 22 insertions(+), 4 deletions(-) diff --git a/python-mocket.changes b/python-mocket.changes index ef63558..193e782 100644 --- a/python-mocket.changes +++ b/python-mocket.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Tue Aug 11 07:08:04 UTC 2020 - Tomáš Chvátal + +- Switch to multibuild as we create cycle with python-pook otherwise + ------------------------------------------------------------------- Sat Aug 8 13:00:29 UTC 2020 - Sebastian Wagner diff --git a/python-mocket.spec b/python-mocket.spec index a54243e..711aff4 100644 --- a/python-mocket.spec +++ b/python-mocket.spec @@ -17,12 +17,19 @@ %{?!python_module:%define python_module() python-%{**} python3-%{**}} -Name: python-mocket +%global flavor @BUILD_FLAVOR@%{nil} +%if "%{flavor}" == "test" +%define psuffix -test +%bcond_without test +%else +%define psuffix %{nil} +%bcond_with test +%endif +Name: python-mocket%{psuffix} Version: 3.8.6 Release: 0 Summary: Python socket mock framework License: BSD-3-Clause -Group: Development/Languages/Python URL: https://github.com/mindflayer/python-mocket Source0: https://files.pythonhosted.org/packages/source/m/mocket/mocket-%{version}.tar.gz BuildRequires: %{python_module setuptools} @@ -38,7 +45,7 @@ Suggests: python-redis Suggests: python-requests Suggests: python-xxhash BuildArch: noarch -# SECTION test requirements +%if %{with test} BuildRequires: %{python_module PySocks} BuildRequires: %{python_module cryptography} BuildRequires: %{python_module decorator} @@ -57,7 +64,7 @@ BuildRequires: %{python_module xxhash} BuildRequires: ca-certificates-mozilla BuildRequires: python3-aiohttp BuildRequires: python3-async_timeout -# /SECTION +%endif %python_subpackages %description @@ -76,11 +83,14 @@ export LANG=en_US.UTF-8 %python_build %install +%if !%{with test} export LANG=en_US.UTF-8 %python_install %python_expand %fdupes %{buildroot}%{$python_sitelib} +%endif %check +%if %{with test} export LANG=en_US.UTF-8 export PYTHONPATH=${PWD} export SKIP_TRUE_HTTP=1 @@ -91,10 +101,13 @@ else $python -m pytest tests/main mocket tests/tests35/ -vv -k 'not RedisTestCase' fi } +%endif +%if !%{with test} %files %{python_files} %doc README.rst %license LICENSE %{python_sitelib}/* +%endif %changelog From 63400cb40032ca282c26f7517c11cf08ca750f68419f0efdff39f1807796b451 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Chv=C3=A1tal?= Date: Tue, 11 Aug 2020 09:12:25 +0000 Subject: [PATCH 2/2] Accepting request 825717 from home:bnavigator:branches:devel:languages:python - Update to version 3.8.7 * This version ships the change to support the libmagic wrapper distributed with file's command. Keeping the skip build in test flavor. See comment. ------------------------------------------------------------------- OBS-URL: https://build.opensuse.org/request/show/825717 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-mocket?expand=0&rev=12 --- _multibuild | 3 +++ mocket-3.8.6.tar.gz | 3 --- mocket-3.8.7.tar.gz | 3 +++ python-mocket.changes | 7 +++++++ python-mocket.spec | 22 +++++++++------------- 5 files changed, 22 insertions(+), 16 deletions(-) create mode 100644 _multibuild delete mode 100644 mocket-3.8.6.tar.gz create mode 100644 mocket-3.8.7.tar.gz diff --git a/_multibuild b/_multibuild new file mode 100644 index 0000000..fcc7b97 --- /dev/null +++ b/_multibuild @@ -0,0 +1,3 @@ + + test + diff --git a/mocket-3.8.6.tar.gz b/mocket-3.8.6.tar.gz deleted file mode 100644 index 5f04865..0000000 --- a/mocket-3.8.6.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:aeaa0ce03473f4770eba0de47392b3d7310356ae3a486b2a3ba14c437f8b9e92 -size 72587 diff --git a/mocket-3.8.7.tar.gz b/mocket-3.8.7.tar.gz new file mode 100644 index 0000000..ae6485b --- /dev/null +++ b/mocket-3.8.7.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3a0f1c01138df8f31e30ce41a54d2726319d9880066936c3019738ba80b842fe +size 73263 diff --git a/python-mocket.changes b/python-mocket.changes index 193e782..337a677 100644 --- a/python-mocket.changes +++ b/python-mocket.changes @@ -1,4 +1,11 @@ ------------------------------------------------------------------- +Tue Aug 11 07:17:16 UTC 2020 - Benjamin Greiner + +- Update to version 3.8.7 + * This version ships the change to support the libmagic wrapper + distributed with file's command. + +------------------------------------------------------------------- Tue Aug 11 07:08:04 UTC 2020 - Tomáš Chvátal - Switch to multibuild as we create cycle with python-pook otherwise diff --git a/python-mocket.spec b/python-mocket.spec index 711aff4..412e8b4 100644 --- a/python-mocket.spec +++ b/python-mocket.spec @@ -26,7 +26,7 @@ %bcond_with test %endif Name: python-mocket%{psuffix} -Version: 3.8.6 +Version: 3.8.7 Release: 0 Summary: Python socket mock framework License: BSD-3-Clause @@ -73,14 +73,15 @@ included, with gevent/asyncio/SSL support. %prep %setup -q -n mocket-%{version} -rm -f setup.cfg pytest.ini tox.ini -sed -i '/pipenv/d' setup.py +sed -i '/cov/ d' setup.cfg +sed -i '/pipenv/ d' setup.py sed -i 's/==/>=/' requirements.txt -touch conftest.py %build +%if !%{with test} export LANG=en_US.UTF-8 %python_build +%endif %install %if !%{with test} @@ -92,22 +93,17 @@ export LANG=en_US.UTF-8 %check %if %{with test} export LANG=en_US.UTF-8 -export PYTHONPATH=${PWD} export SKIP_TRUE_HTTP=1 -%{python_expand # -if [ $python = python2 ]; then - $python -m pytest tests/main mocket -vv -k 'not RedisTestCase' -else - $python -m pytest tests/main mocket tests/tests35/ -vv -k 'not RedisTestCase' -fi -} +%define pytest_ignore_python2 --ignore tests/tests35 --ignore tests/tests38 +%pytest -k 'not RedisTestCase' %{?pytest_ignore%{$python_version}} %endif %if !%{with test} %files %{python_files} %doc README.rst %license LICENSE -%{python_sitelib}/* +%{python_sitelib}/mocket +%{python_sitelib}/mocket-%{version}-py*.egg-info %endif %changelog