[pypy-svn] r32672 - pypy/dist/pypy/objspace/cclp/constraint/test

auc at codespeak.net auc at codespeak.net
Wed Sep 27 18:16:27 CEST 2006


Author: auc
Date: Wed Sep 27 18:16:25 2006
New Revision: 32672

Modified:
   pypy/dist/pypy/objspace/cclp/constraint/test/test_fd.py
Log:
one more test (for __eq__ and __ne__ on domains)


Modified: pypy/dist/pypy/objspace/cclp/constraint/test/test_fd.py
==============================================================================
--- pypy/dist/pypy/objspace/cclp/constraint/test/test_fd.py	(original)
+++ pypy/dist/pypy/objspace/cclp/constraint/test/test_fd.py	Wed Sep 27 18:16:25 2006
@@ -20,6 +20,15 @@
     def test_remove_all_values(self):
         fd = FiniteDomain([3])
         raises(ConsistencyError, fd.remove_value, 3) 
+
+
+    def test_predicates(self):
+        fd1 = FiniteDomain([3])
+        fd2 = FiniteDomain([3, 4]) 
+        assert fd1 != fd2
+        assert not (fd1 == fd2)
+        assert fd1 == FiniteDomain([3])
+        assert not (fd1 != FiniteDomain([3]))
         
     def test_remove_values(self):
         fd = FiniteDomain([1, 2, 3])



More information about the Pypy-commit mailing list