Files
deb-python-eventlet/tests/patcher/shared1.py
Sergey Shepelev b7b357189d test_import_patched_defaults bended to play with pyopenssl>=16.1.0
Basically this patch replaces urllib with custom module that is guaranteed not imported before patching.
https://github.com/eventlet/eventlet/issues/362

More general issue here https://github.com/eventlet/eventlet/issues/368
2016-12-31 20:50:04 +03:00

12 lines
366 B
Python

import os
__test__ = False
shared = None
if os.environ.get('eventlet_test_in_progress') == 'yes':
# pyopenssl imported urllib before we could patch it
# we can ensure this shared module was not imported
# https://github.com/eventlet/eventlet/issues/362
import tests.patcher.shared_import_socket as shared
_ = shared # mask unused import error