Debian Codegraph @

pypy/interpreter/astcompiler/test/stdlib_testall.py

raw symbols SCIP
1 import py
2 from pypy.interpreter.astcompiler.test.test_compiler import compile_with_astcompiler
3
4 class TestStdlib:
5
6 def check_file_compile(self, filepath):
7 space = self.space
8 print 'Compiling:', filepath
9 source = filepath.read()
10 compile_with_astcompiler(source, mode='exec', space=space)
11
12 def test_all(self):
13 space = self.space
14 libpythondir = space.str_w(space.appexec((), """():
15 import os
16 return os.path.dirname(os.__file__)"""))
17 p = py.path.local(libpythondir)
18 files = p.listdir("*.py")
19 files.sort()
20 for s in files:
21 yield self.check_file_compile, s