diff options
author | Konstantinos Koukopoulos <koukopoulos@gmail.com> | 2014-01-30 20:15:25 +0200 |
---|---|---|
committer | Konstantinos Koukopoulos <koukopoulos@gmail.com> | 2014-01-30 20:15:25 +0200 |
commit | 410d04255a204d180650eaf86890e1b389a36dbc (patch) | |
tree | 06dc9ded93b19061f6e546f97588f9c371321edf | |
parent | c8b13eae2416e92118b1d1245ece09fc574e2046 (diff) | |
download | pyopenssl-410d04255a204d180650eaf86890e1b389a36dbc.tar.gz |
allow tests to run even without execinfo.h
-rw-r--r-- | OpenSSL/test/util.py | 6 | ||||
-rw-r--r-- | runtests.py | 5 |
2 files changed, 9 insertions, 2 deletions
diff --git a/OpenSSL/test/util.py b/OpenSSL/test/util.py index 011e7da..4e4d812 100644 --- a/OpenSSL/test/util.py +++ b/OpenSSL/test/util.py @@ -17,7 +17,11 @@ import sys from OpenSSL._util import exception_from_error_queue from OpenSSL.crypto import Error -import memdbg +try: + import memdbg +except Exception: + class _memdbg(object): heap = None + memdbg = _memdbg() from OpenSSL._util import ffi, lib, byte_string as b diff --git a/runtests.py b/runtests.py index 2ec425b..13f5c4c 100644 --- a/runtests.py +++ b/runtests.py @@ -2,7 +2,10 @@ import sys sys.modules['ssl'] = None sys.modules['_hashlib'] = None -import memdbg +try: + import memdbg +except Exception as e: + pass from twisted.scripts.trial import run run() |