1.1 --- a/tests/attribute_access_type_restriction_conditional.py Fri Sep 10 00:27:49 2010 +0200 1.2 +++ b/tests/attribute_access_type_restriction_conditional.py Sat Sep 11 21:45:24 2010 +0200 1.3 @@ -25,6 +25,7 @@ 1.4 return 5 1.5 1.6 def test_conditional(obj): 1.7 + # obj: f, g; f 1.8 if obj.f(): 1.9 obj.g() 1.10 return 2
2.1 --- a/tests/attribute_access_type_restriction_conditional_choice.py Fri Sep 10 00:27:49 2010 +0200 2.2 +++ b/tests/attribute_access_type_restriction_conditional_choice.py Sat Sep 11 21:45:24 2010 +0200 2.3 @@ -19,12 +19,11 @@ 2.4 return 5 2.5 2.6 def test_conditional(obj): 2.7 - # obj: C, D, E (f) 2.8 - if obj.f(): # C, D, E (f) 2.9 - return obj.g() # D (f, g) 2.10 + # obj: f, g; f, h 2.11 + if obj.f(): 2.12 + return obj.g() 2.13 else: 2.14 - return obj.h() # E (f, h) 2.15 - # # (f, g) ^ (f, h) 2.16 + return obj.h() 2.17 2.18 c = C() 2.19 d = D()
3.1 --- a/tests/attribute_access_type_restriction_conditional_choice_incompatible.py Fri Sep 10 00:27:49 2010 +0200 3.2 +++ b/tests/attribute_access_type_restriction_conditional_choice_incompatible.py Sat Sep 11 21:45:24 2010 +0200 3.3 @@ -12,12 +12,11 @@ 3.4 return 3 3.5 3.6 def test_conditional(obj): 3.7 - # obj: C, D (f) 3.8 - if obj.f(): # C, D (f) 3.9 - return obj.g() # D (f, g) 3.10 + # obj: f, g; f 3.11 + if obj.f(): 3.12 + return obj.g() 3.13 else: 3.14 - return obj.f() # C (f) 3.15 - # # (f, g) ^ (f) 3.16 + return obj.f() 3.17 3.18 c = C() 3.19 d = D()
4.1 --- a/tests/attribute_access_type_restriction_new.py Fri Sep 10 00:27:49 2010 +0200 4.2 +++ b/tests/attribute_access_type_restriction_new.py Sat Sep 11 21:45:24 2010 +0200 4.3 @@ -24,9 +24,9 @@ 4.4 return 5 4.5 4.6 def test_new(obj, obj2): 4.7 - # obj should provide f 4.8 + # obj: f 4.9 if obj.f(): 4.10 - obj = obj2 # should provide f, g 4.11 + obj = obj2 # obj: f, g 4.12 obj.g() 4.13 return obj.f() 4.14
5.1 --- a/tests/attribute_access_type_restriction_new_conditional.py Fri Sep 10 00:27:49 2010 +0200 5.2 +++ b/tests/attribute_access_type_restriction_new_conditional.py Sat Sep 11 21:45:24 2010 +0200 5.3 @@ -19,14 +19,13 @@ 5.4 return 5 5.5 5.6 def test_new_conditional(obj, obj2): 5.7 - # obj: 5.8 - # obj2: 5.9 - if obj.f(): # C, D, E (f) 5.10 - obj = obj2 # obj: D (g) 5.11 - obj.g() # D (g) 5.12 + # obj: f; f, h 5.13 + if obj.f(): 5.14 + obj = obj2 # obj: g 5.15 + obj.g() 5.16 else: 5.17 - obj.h() # E (f, h) 5.18 - # # (g) ^ (f, h) 5.19 + obj.h() 5.20 + 5.21 return 5 5.22 5.23 c = C()
6.1 --- a/tests/attribute_access_type_restriction_single.py Fri Sep 10 00:27:49 2010 +0200 6.2 +++ b/tests/attribute_access_type_restriction_single.py Sat Sep 11 21:45:24 2010 +0200 6.3 @@ -19,9 +19,9 @@ 6.4 return 5 6.5 6.6 def test_one(obj): 6.7 - # obj: D (f, g) 6.8 - obj.f() # C, D, E (f) 6.9 - return obj.g() # D (f, g) 6.10 + # obj: f, g 6.11 + obj.f() 6.12 + return obj.g() 6.13 6.14 c = C() 6.15 d = D()
7.1 --- a/tests/attribute_access_type_restriction_single_instance.py Fri Sep 10 00:27:49 2010 +0200 7.2 +++ b/tests/attribute_access_type_restriction_single_instance.py Sat Sep 11 21:45:24 2010 +0200 7.3 @@ -24,9 +24,9 @@ 7.4 return 5 7.5 7.6 def test_one(obj): 7.7 - # obj: D (f, g) 7.8 - obj.f() # C, D, E (f) 7.9 - return obj.g # D (f, g) - instance only 7.10 + # obj: f, g 7.11 + obj.f() 7.12 + return obj.g 7.13 7.14 c = C() 7.15 d = D(4)