micropython

Change of tests/compare_equality.py

354:978dc8a73ef5
tests/compare_equality.py
     1.1 --- a/tests/compare_equality.py	Sat Aug 07 02:06:15 2010 +0200
     1.2 +++ b/tests/compare_equality.py	Mon Aug 09 01:23:05 2010 +0200
     1.3 @@ -4,13 +4,16 @@
     1.4  b = 2
     1.5  
     1.6  class X:
     1.7 -    def __contains__(self, other):
     1.8 +    def __eq__(self, other):
     1.9 +        return 0
    1.10 +    def __ne__(self, other):
    1.11          return 1
    1.12  
    1.13  x = X()
    1.14  
    1.15  result_1 = 0
    1.16  result_2 = 2
    1.17 +result_3 = 3
    1.18  
    1.19  if a != x != b:
    1.20      result_1 = 1
    1.21 @@ -18,4 +21,7 @@
    1.22  if a == x != b:
    1.23      result_2 = 0
    1.24  
    1.25 +if a == x:
    1.26 +    result_3 = 0
    1.27 +
    1.28  # vim: tabstop=4 expandtab shiftwidth=4