diff options
author | Brian Curtin <brian@python.org> | 2012-02-01 21:20:03 (GMT) |
---|---|---|
committer | Brian Curtin <brian@python.org> | 2012-02-01 21:20:03 (GMT) |
commit | 97e200864575d86516c4dde3ecf6eedf3d534930 (patch) | |
tree | 389de82dfeb8abd053790976eed226d81ef968e7 /Lib/sqlite3/test/dbapi.py | |
parent | 8d132c88c2dd8a19f8accd9ef3d4c8f33d2a9a6b (diff) | |
parent | 8940f6242c27fa1c3349503f71903b2b79069994 (diff) | |
download | cpython-97e200864575d86516c4dde3ecf6eedf3d534930.zip cpython-97e200864575d86516c4dde3ecf6eedf3d534930.tar.gz cpython-97e200864575d86516c4dde3ecf6eedf3d534930.tar.bz2 |
merge updates
Diffstat (limited to 'Lib/sqlite3/test/dbapi.py')
-rw-r--r-- | Lib/sqlite3/test/dbapi.py | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/Lib/sqlite3/test/dbapi.py b/Lib/sqlite3/test/dbapi.py index 518b8ae..202bd38 100644 --- a/Lib/sqlite3/test/dbapi.py +++ b/Lib/sqlite3/test/dbapi.py @@ -225,6 +225,13 @@ class CursorTests(unittest.TestCase): def CheckExecuteArgString(self): self.cu.execute("insert into test(name) values (?)", ("Hugo",)) + def CheckExecuteArgStringWithZeroByte(self): + self.cu.execute("insert into test(name) values (?)", ("Hu\x00go",)) + + self.cu.execute("select name from test where id=?", (self.cu.lastrowid,)) + row = self.cu.fetchone() + self.assertEqual(row[0], "Hu\x00go") + def CheckExecuteWrongNoOfArgs1(self): # too many parameters try: |