diff options
author | Victor Stinner <victor.stinner@gmail.com> | 2013-12-19 15:38:03 (GMT) |
---|---|---|
committer | Victor Stinner <victor.stinner@gmail.com> | 2013-12-19 15:38:03 (GMT) |
commit | cb1f74ec405b81dd1319b616829dd576a48603f8 (patch) | |
tree | 99573ccb27a730f4eec2cf0b6b131823668738b6 /Lib/sqlite3 | |
parent | cac23a50ee2979b8c2e3472e6b13efb1a8bd4f78 (diff) | |
download | cpython-cb1f74ec405b81dd1319b616829dd576a48603f8.zip cpython-cb1f74ec405b81dd1319b616829dd576a48603f8.tar.gz cpython-cb1f74ec405b81dd1319b616829dd576a48603f8.tar.bz2 |
Issue #20026: Fix the sqlite module to handle correctly invalid isolation level
(wrong type).
Diffstat (limited to 'Lib/sqlite3')
-rw-r--r-- | Lib/sqlite3/test/regression.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/Lib/sqlite3/test/regression.py b/Lib/sqlite3/test/regression.py index b927cb3..c557ab6 100644 --- a/Lib/sqlite3/test/regression.py +++ b/Lib/sqlite3/test/regression.py @@ -330,6 +330,11 @@ class RegressionTests(unittest.TestCase): datetime.datetime(2012, 4, 4, 15, 6, 0, 123456), ]) + def CheckInvalidIsolationLevelType(self): + # isolation level is a string, not an integer + self.assertRaises(TypeError, + sqlite.connect, ":memory:", isolation_level=123) + def suite(): regression_suite = unittest.makeSuite(RegressionTests, "Check") |