Hello community,
here is the log from the commit of package python-oslotest for openSUSE:Factory
checked in at 2019-08-15 12:25:38
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-oslotest (Old)
and /work/SRC/openSUSE:Factory/.python-oslotest.new.9556 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-oslotest"
Thu Aug 15 12:25:38 2019 rev:18 rq:721086 version:3.7.1
Changes:
--------
--- /work/SRC/openSUSE:Factory/python-oslotest/python-oslotest.changes
2019-04-12 09:13:45.361652900 +0200
+++
/work/SRC/openSUSE:Factory/.python-oslotest.new.9556/python-oslotest.changes
2019-08-15 12:25:39.982602210 +0200
@@ -1,0 +2,5 @@
+Mon Aug 5 14:48:03 UTC 2019 - [email protected]
+
+- added 0001-Stop-testing-mock-functionality.patch
+
+-------------------------------------------------------------------
New:
----
0001-Stop-testing-mock-functionality.patch
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ python-oslotest.spec ++++++
--- /var/tmp/diff_new_pack.qHD4wZ/_old 2019-08-15 12:25:41.382601861 +0200
+++ /var/tmp/diff_new_pack.qHD4wZ/_new 2019-08-15 12:25:41.382601861 +0200
@@ -24,6 +24,8 @@
Group: Development/Languages/Python
URL: https://launchpad.net/oslotest
Source0:
https://files.pythonhosted.org/packages/source/o/oslotest/oslotest-3.7.1.tar.gz
+# https://review.opendev.org/#/c/672522/
+Patch0: 0001-Stop-testing-mock-functionality.patch
BuildRequires: openstack-macros
BuildRequires: python-devel
BuildRequires: python2-debtcollector >= 1.2.0
@@ -71,7 +73,7 @@
better support for mocking results.
%prep
-%autosetup -n oslotest-%{version}
+%autosetup -p1 -n oslotest-%{version}
%py_req_cleanup
%build
++++++ 0001-Stop-testing-mock-functionality.patch ++++++
>From f8f6b14088637fd87de7cf385b840d6b5e5f9b22 Mon Sep 17 00:00:00 2001
From: Ben Nemec <[email protected]>
Date: Tue, 28 May 2019 17:04:19 +0000
Subject: [PATCH] Stop testing mock functionality
There's no particular reason for us to be verifying mock's behavior.
They have their own unit tests for doing that.
This is specifically a problem right now because mock changed its
behavior in 3.0.0 and broke this test: "Issue #36366: Calling stop()
on an unstarted or stopped unittest.mock.patch() object will now
return None instead of raising RuntimeError, making the method
idempotent."
Change-Id: I57db9bad15cab343e152615e115e2ba3ac4d87fe
Closes-Bug: 1830429
---
oslotest/tests/unit/test_base.py | 8 --------
1 file changed, 8 deletions(-)
diff --git a/oslotest/tests/unit/test_base.py b/oslotest/tests/unit/test_base.py
index 93c3c52..b98c672 100644
--- a/oslotest/tests/unit/test_base.py
+++ b/oslotest/tests/unit/test_base.py
@@ -126,14 +126,6 @@ class TestManualMock(base.BaseTestCase):
self.addCleanup(patcher.stop)
super(TestManualMock, self).setUp()
self.useFixture(fixtures.MockPatch('fixtures.Timeout'))
- self.unstopped = mock.patch('os.environ.put')
-
- def tearDown(self):
- super(TestManualMock, self).tearDown()
- self.assertRaises(
- RuntimeError,
- self.unstopped.stop,
- )
def test_mock_patch_manually(self):
# Verify that if a test instance creates its own mock and
--
2.22.0