run total_ordering() tests, and fix the function (default comparisons shouldn't be considered)

This commit is contained in:
Benjamin Peterson 2010-08-23 17:40:33 +00:00
parent 7311729790
commit 9c2930e4be
2 changed files with 6 additions and 2 deletions

View file

@ -481,7 +481,7 @@ class TestTotalOrdering(unittest.TestCase):
# new methods should not overwrite existing
@functools.total_ordering
class A(int):
raise Exception()
pass
self.assert_(A(1) < A(2))
self.assert_(A(2) > A(1))
self.assert_(A(1) <= A(2))
@ -564,6 +564,7 @@ def test_main(verbose=None):
TestPartialSubclass,
TestPythonPartial,
TestUpdateWrapper,
TestTotalOrdering,
TestWraps,
TestReduce,
TestLRU,