summaryrefslogtreecommitdiffstats
path: root/Lib/sqlite3/test/hooks.py
diff options
context:
space:
mode:
authorGregory P. Smith <greg@mad-scientist.com>2009-07-04 08:42:10 (GMT)
committerGregory P. Smith <greg@mad-scientist.com>2009-07-04 08:42:10 (GMT)
commit1844b0d7481d0790909627e4a166ef046df2c590 (patch)
treebf851db345c8b7ec2cf1288a0dc447313a0c18f4 /Lib/sqlite3/test/hooks.py
parentcd947e0c6af9b81d5069cb57080f1d0eedec7bfd (diff)
downloadcpython-1844b0d7481d0790909627e4a166ef046df2c590.zip
cpython-1844b0d7481d0790909627e4a166ef046df2c590.tar.gz
cpython-1844b0d7481d0790909627e4a166ef046df2c590.tar.bz2
Merge r73838 from py3k branch. Use the nondeprecated unittest method
names.
Diffstat (limited to 'Lib/sqlite3/test/hooks.py')
-rw-r--r--Lib/sqlite3/test/hooks.py10
1 files changed, 5 insertions, 5 deletions
diff --git a/Lib/sqlite3/test/hooks.py b/Lib/sqlite3/test/hooks.py
index 547dc65..2745c8b 100644
--- a/Lib/sqlite3/test/hooks.py
+++ b/Lib/sqlite3/test/hooks.py
@@ -37,7 +37,7 @@ class CollationTests(unittest.TestCase):
con.create_collation("X", 42)
self.fail("should have raised a TypeError")
except TypeError, e:
- self.failUnlessEqual(e.args[0], "parameter must be callable")
+ self.assertEqual(e.args[0], "parameter must be callable")
def CheckCreateCollationNotAscii(self):
con = sqlite.connect(":memory:")
@@ -74,7 +74,7 @@ class CollationTests(unittest.TestCase):
result = con.execute(sql).fetchall()
self.fail("should have raised an OperationalError")
except sqlite.OperationalError, e:
- self.failUnlessEqual(e.args[0].lower(), "no such collation sequence: mycoll")
+ self.assertEqual(e.args[0].lower(), "no such collation sequence: mycoll")
def CheckCollationRegisterTwice(self):
"""
@@ -119,7 +119,7 @@ class ProgressTests(unittest.TestCase):
con.execute("""
create table foo(a, b)
""")
- self.failUnless(progress_calls)
+ self.assertTrue(progress_calls)
def CheckOpcodeCount(self):
@@ -143,7 +143,7 @@ class ProgressTests(unittest.TestCase):
create table bar (a, b)
""")
second_count = len(progress_calls)
- self.failUnless(first_count > second_count)
+ self.assertTrue(first_count > second_count)
def CheckCancelOperation(self):
"""
@@ -173,7 +173,7 @@ class ProgressTests(unittest.TestCase):
con.set_progress_handler(progress, 1)
con.set_progress_handler(None, 1)
con.execute("select 1 union select 2 union select 3").fetchall()
- self.failUnlessEqual(action, 0, "progress handler was not cleared")
+ self.assertEqual(action, 0, "progress handler was not cleared")
def suite():
collation_suite = unittest.makeSuite(CollationTests, "Check")