diff options
author | Benjamin Peterson <benjamin@python.org> | 2009-06-30 23:06:06 (GMT) |
---|---|---|
committer | Benjamin Peterson <benjamin@python.org> | 2009-06-30 23:06:06 (GMT) |
commit | c9c0f201fed21efcf669dbbf5f923eaf0eeb1db9 (patch) | |
tree | 6350dab0b481e6de307dc4e043c6230f463a9ca7 /Lib/test/test_csv.py | |
parent | 98d23f2e065713ccfbc07d9a0b65f737a212bfb5 (diff) | |
download | cpython-c9c0f201fed21efcf669dbbf5f923eaf0eeb1db9.zip cpython-c9c0f201fed21efcf669dbbf5f923eaf0eeb1db9.tar.gz cpython-c9c0f201fed21efcf669dbbf5f923eaf0eeb1db9.tar.bz2 |
convert old fail* assertions to assert*
Diffstat (limited to 'Lib/test/test_csv.py')
-rw-r--r-- | Lib/test/test_csv.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/Lib/test/test_csv.py b/Lib/test/test_csv.py index 7eb3a7f..95105be 100644 --- a/Lib/test/test_csv.py +++ b/Lib/test/test_csv.py @@ -315,7 +315,7 @@ class TestDialectRegistry(unittest.TestCase): expected_dialects.sort() csv.register_dialect(name, myexceltsv) try: - self.failUnless(csv.get_dialect(name).delimiter, '\t') + self.assertTrue(csv.get_dialect(name).delimiter, '\t') got_dialects = csv.list_dialects() got_dialects.sort() self.assertEqual(expected_dialects, got_dialects) @@ -326,8 +326,8 @@ class TestDialectRegistry(unittest.TestCase): name = 'fedcba' csv.register_dialect(name, delimiter=';') try: - self.failUnless(csv.get_dialect(name).delimiter, '\t') - self.failUnless(list(csv.reader('X;Y;Z', name)), ['X', 'Y', 'Z']) + self.assertTrue(csv.get_dialect(name).delimiter, '\t') + self.assertTrue(list(csv.reader('X;Y;Z', name)), ['X', 'Y', 'Z']) finally: csv.unregister_dialect(name) @@ -811,7 +811,7 @@ Stonecutters Seafood and Chop House, Lemont, IL, 12/19/02, Week Back # given that all three lines in sample3 are equal, # I think that any character could have been 'guessed' as the # delimiter, depending on dictionary order - self.assert_(dialect.delimiter in self.sample3) + self.assertTrue(dialect.delimiter in self.sample3) dialect = sniffer.sniff(self.sample3, delimiters="?,") self.assertEqual(dialect.delimiter, "?") dialect = sniffer.sniff(self.sample3, delimiters="/,") |