summaryrefslogtreecommitdiff
path: root/test/DocutilsTestSupport.py
diff options
context:
space:
mode:
authorgrubert <grubert@929543f6-e4f2-0310-98a6-ba3bd3dd1d04>2012-05-01 08:34:41 +0000
committergrubert <grubert@929543f6-e4f2-0310-98a6-ba3bd3dd1d04>2012-05-01 08:34:41 +0000
commit9685f6327fae73fabc6061fe63088022fa4f0c78 (patch)
tree34b14a12cab0eeed62c39e822ea1d9d6efd59f3e /test/DocutilsTestSupport.py
parent5a40cb0a9646e80fcf52aca936440f0c22b81276 (diff)
downloaddocutils-9685f6327fae73fabc6061fe63088022fa4f0c78.tar.gz
python 2.3 alias unittest.TestCase.assertTrue (possibly reverted on next release)
git-svn-id: http://svn.code.sf.net/p/docutils/code/trunk/docutils@7400 929543f6-e4f2-0310-98a6-ba3bd3dd1d04
Diffstat (limited to 'test/DocutilsTestSupport.py')
-rw-r--r--test/DocutilsTestSupport.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/test/DocutilsTestSupport.py b/test/DocutilsTestSupport.py
index 5cf95e6fc..bbe01a807 100644
--- a/test/DocutilsTestSupport.py
+++ b/test/DocutilsTestSupport.py
@@ -123,6 +123,10 @@ class StandardTestCase(unittest.TestCase):
raise self.failureException, \
(msg or '%s == %s' % _format_str(first, second))
+ # python 2.3
+ if not hasattr(unittest.TestCase, "assertTrue"):
+ assertTrue = unittest.TestCase.failUnless
+
# aliases for assertion methods, deprecated since Python 2.7
failUnlessEqual = assertEquals = assertEqual