blob: f66b9c5bd43b3671e9a054433e9f1fa73f1f3a3c (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
|
"""Test file for run_python_file."""
import pprint, sys
DATA = "xyzzy"
import __main__
def my_function(a):
return "my_fn(%r)" % a
FN_VAL = my_function("fooey")
globals_to_check = {
'__name__': __name__,
'__file__': __file__,
'__doc__': __doc__,
'DATA': DATA,
'FN_VAL': FN_VAL,
'__main__.DATA': getattr(__main__, "DATA", "nothing"),
'argv': sys.argv,
'path0': sys.path[0],
}
pprint.pprint(globals_to_check)
|