diff options
Diffstat (limited to 'tests/test_errcodes.py')
-rwxr-xr-x | tests/test_errcodes.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/tests/test_errcodes.py b/tests/test_errcodes.py index accee56..4848a76 100755 --- a/tests/test_errcodes.py +++ b/tests/test_errcodes.py @@ -27,7 +27,10 @@ from testutils import unittest, ConnectingTestCase, slow try: reload except NameError: - from imp import reload + try: + from importlib import reload + except ImportError: + from imp import reload from threading import Thread from psycopg2 import errorcodes |