test_ast: pass the filename to ast.parse()

This commit is contained in:
Victor Stinner 2013-03-22 00:06:20 +01:00
parent 6d3d0fe0b2
commit d502a07fac

View file

@ -947,7 +947,7 @@ class ASTValidatorTests(unittest.TestCase):
fn = os.path.join(stdlib, module)
with open(fn, "r", encoding="utf-8") as fp:
source = fp.read()
mod = ast.parse(source)
mod = ast.parse(source, fn)
compile(mod, fn, "exec")