From 078ed6f153e1189ac051ee3820c6381fee41d12a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stefan=20K=C3=B6gl?= Date: Sun, 7 Jul 2013 19:25:19 +0200 Subject: add test for comparing a pointer to another object --- tests.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/tests.py b/tests.py index 762313d..8f86439 100755 --- a/tests.py +++ b/tests.py @@ -62,6 +62,9 @@ class ComparisonTests(unittest.TestCase): self.assertNotEqual(hash(p1), hash(p3)) self.assertNotEqual(hash(p2), hash(p3)) + # a pointer compares not-equal to objects of other types + self.assertFalse(p1 == "/something/1/b") + suite = unittest.TestSuite() suite.addTest(unittest.makeSuite(SpecificationTests)) suite.addTest(unittest.makeSuite(ComparisonTests)) -- cgit v1.2.1