Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package python-PyBrowserID for openSUSE:Factory checked in at 2021-06-01 10:37:35 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/python-PyBrowserID (Old) and /work/SRC/openSUSE:Factory/.python-PyBrowserID.new.1898 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-PyBrowserID" Tue Jun 1 10:37:35 2021 rev:4 rq:895756 version:0.14.0 Changes: -------- --- /work/SRC/openSUSE:Factory/python-PyBrowserID/python-PyBrowserID.changes 2019-11-08 15:25:01.906950691 +0100 +++ /work/SRC/openSUSE:Factory/.python-PyBrowserID.new.1898/python-PyBrowserID.changes 2021-06-01 10:38:49.528952353 +0200 @@ -1,0 +2,7 @@ +Thu May 27 08:31:12 UTC 2021 - [email protected] + +- %check: use %pyunittest rpm macro +- Add python-PyBrowserID-unittest-mock.patch removes dependency + on mock package (gh#mozilla/PyBrowserID#42). + +------------------------------------------------------------------- New: ---- python-PyBrowserID-unittest-mock.patch ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ python-PyBrowserID.spec ++++++ --- /var/tmp/diff_new_pack.K5ehJq/_old 2021-06-01 10:38:50.112953347 +0200 +++ /var/tmp/diff_new_pack.K5ehJq/_new 2021-06-01 10:38:50.116953355 +0200 @@ -1,7 +1,7 @@ # # spec file for package python-PyBrowserID # -# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany. +# Copyright (c) 2021 SUSE LLC # Copyright (c) 2017-2018 The openSUSE Project. # # All modifications and additions to the file contributed by third parties @@ -18,7 +18,6 @@ %{?!python_module:%define python_module() python-%{**} python3-%{**}} -%bcond_without test Name: python-PyBrowserID Version: 0.14.0 Release: 0 @@ -26,15 +25,19 @@ License: MPL-2.0 URL: https://github.com/mozilla/PyBrowserID Source: https://files.pythonhosted.org/packages/source/P/PyBrowserID/PyBrowserID-%{version}.tar.gz +# https://github.com/mozilla/PyBrowserID/issues/42 +Patch0: python-PyBrowserID-unittest-mock.patch BuildRequires: %{python_module setuptools} BuildRequires: fdupes BuildRequires: python-rpm-macros Requires: python-requests BuildArch: noarch -%if %{with test} +# SECTION test requirements +%if %{suse_version} < 1550 BuildRequires: %{python_module mock} -BuildRequires: %{python_module requests} %endif +BuildRequires: %{python_module requests} +# /SECTION %python_subpackages %description @@ -43,6 +46,7 @@ %prep %setup -q -n PyBrowserID-%{version} +%patch0 -p1 %build %python_build @@ -51,10 +55,8 @@ %python_install %python_expand %fdupes %{buildroot}%{$python_sitelib} -%if %{with test} %check -%python_exec setup.py test -%endif +%pyunittest discover -v %files %{python_files} %doc CHANGES.txt README.rst ++++++ python-PyBrowserID-unittest-mock.patch ++++++ Index: PyBrowserID-0.14.0/browserid/tests/test_supportdoc.py =================================================================== --- PyBrowserID-0.14.0.orig/browserid/tests/test_supportdoc.py 2014-12-12 06:15:36.000000000 +0100 +++ PyBrowserID-0.14.0/browserid/tests/test_supportdoc.py 2021-05-27 11:15:09.807769893 +0200 @@ -1,7 +1,11 @@ import json import socket -from mock import Mock, patch +try: + from unittest.mock import Mock, patch +except ImportError: + from mock import Mock, patch + from requests.exceptions import RequestException from browserid.supportdoc import fetch_support_document, SupportDocumentManager Index: PyBrowserID-0.14.0/browserid/tests/test_verifiers.py =================================================================== --- PyBrowserID-0.14.0.orig/browserid/tests/test_verifiers.py 2018-01-11 22:01:14.000000000 +0100 +++ PyBrowserID-0.14.0/browserid/tests/test_verifiers.py 2021-05-27 11:15:59.064034201 +0200 @@ -5,7 +5,11 @@ import time import warnings -from mock import Mock, patch +try: + from unittest.mock import Mock, patch +except ImportError: + from mock import Mock, patch + import browserid from browserid.tests.support import (patched_supportdoc_fetching,
