[Python-checkins] r79946 - in python/branches/py3k: Lib/test/test_functools.py

benjamin.peterson python-checkins at python.org
Sun Apr 11 03:43:16 CEST 2010


Author: benjamin.peterson
Date: Sun Apr 11 03:43:16 2010
New Revision: 79946

Log:
Merged revisions 79944 via svnmerge from 
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r79944 | benjamin.peterson | 2010-04-10 20:40:32 -0500 (Sat, 10 Apr 2010) | 1 line
  
  add test for class with no operations defined
........


Modified:
   python/branches/py3k/   (props changed)
   python/branches/py3k/Lib/test/test_functools.py

Modified: python/branches/py3k/Lib/test/test_functools.py
==============================================================================
--- python/branches/py3k/Lib/test/test_functools.py	(original)
+++ python/branches/py3k/Lib/test/test_functools.py	Sun Apr 11 03:43:16 2010
@@ -448,6 +448,11 @@
         self.assert_(A(2) <= A(2))
         self.assert_(A(2) >= A(2))
 
+    def test_no_operations_defined(self):
+        with self.assertRaises(ValueError):
+            @functools.total_ordering
+            class A:
+                pass
 
 def test_main(verbose=None):
     test_classes = (


More information about the Python-checkins mailing list