summaryrefslogtreecommitdiff
path: root/testing/tests/sqlcipher/test_backend.py
diff options
context:
space:
mode:
Diffstat (limited to 'testing/tests/sqlcipher/test_backend.py')
-rw-r--r--testing/tests/sqlcipher/test_backend.py9
1 files changed, 6 insertions, 3 deletions
diff --git a/testing/tests/sqlcipher/test_backend.py b/testing/tests/sqlcipher/test_backend.py
index caacba0d..643fa041 100644
--- a/testing/tests/sqlcipher/test_backend.py
+++ b/testing/tests/sqlcipher/test_backend.py
@@ -21,8 +21,11 @@ import os
import pytest
import time
import threading
-
-from pysqlcipher import dbapi2
+import sys
+if sys.version_info[0] < 3:
+ from pysqlcipher import dbapi2
+else:
+ from pysqlcipher3 import dbapi2
from testscenarios import TestWithScenarios
# l2db stuff.
@@ -148,7 +151,7 @@ class TestSQLCipherDatabase(tests.TestCase):
def run(self):
try:
db2 = SQLCipherDatabaseTesting(dbname, 2)
- except Exception, e:
+ except Exception as e:
SecondTry.outcome2.append(e)
else:
SecondTry.outcome2.append(db2)