Catch RuntimeError on unpatching in case of multiple unpatching.

This commit is contained in:
Steve Pulec 2018-04-06 09:26:47 -04:00
parent 774de0d54d
commit 2ee484990d

View File

@ -206,8 +206,15 @@ class ResponsesMockAWS(BaseMockAWS):
)
def disable_patching(self):
try:
botocore_mock.stop()
except RuntimeError:
pass
try:
responses.stop()
except RuntimeError:
pass
MockAWS = ResponsesMockAWS