UT: Fix "RuntimeError: stop called on unstarted patcher"
By removing explicit addCleanup calls. Closes-Bug: #1608303 Change-Id: I3744e7378cc809f1a5b1e1384d82ec154f6e2819
This commit is contained in:
parent
c612a729e7
commit
fa5f520bfa
@ -34,7 +34,6 @@ class CLITestV20TapFlowJSON(test_cli20.CLITestV20Base):
|
||||
def _create_patch(self, name, func=None):
|
||||
patcher = mock.patch(name)
|
||||
thing = patcher.start()
|
||||
self.addCleanup(patcher.stop)
|
||||
return thing
|
||||
|
||||
def _mock_extension_loading(self):
|
||||
|
@ -34,7 +34,6 @@ class CLITestV20TapServiceJSON(test_cli20.CLITestV20Base):
|
||||
def _create_patch(self, name, func=None):
|
||||
patcher = mock.patch(name)
|
||||
thing = patcher.start()
|
||||
self.addCleanup(patcher.stop)
|
||||
return thing
|
||||
|
||||
def _mock_extension_loading(self):
|
||||
|
Loading…
x
Reference in New Issue
Block a user