]> granicus.if.org Git - python/commitdiff
Fix test for free ref to global. This test should have caught a
authorJeremy Hylton <jeremy@alum.mit.edu>
Tue, 30 Jan 2001 01:26:53 +0000 (01:26 +0000)
committerJeremy Hylton <jeremy@alum.mit.edu>
Tue, 30 Jan 2001 01:26:53 +0000 (01:26 +0000)
recently fixed bug, but it checked for the wrong answer.

Lib/test/test_scope.py

index c5663014ac01b8ce2515bd7943e3368f0e1180d6..8be3f6185f828f4ad50c201ae4986f9e4ecf2e15 100644 (file)
@@ -86,7 +86,7 @@ def make_adder6(x):
 inc = make_adder6(1)
 plus10 = make_adder6(10)
 
-verify(inc(1) == 2)
+verify(inc(1) == 11) # there's only one global
 verify(plus10(-2) == 8)
 
 print "7. nearest enclosing scope"