MCPcopy Index your code
hub / github.com/python/cpython / test

Function test

Tools/freeze/makeconfig.py:39–56  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

37# Test program.
38
39def test():
40 if not sys.argv[3:]:
41 print('usage: python makeconfig.py config.c.in outputfile', end=' ')
42 print('modulename ...')
43 sys.exit(2)
44 if sys.argv[1] == '-':
45 infp = sys.stdin
46 else:
47 infp = open(sys.argv[1])
48 if sys.argv[2] == '-':
49 outfp = sys.stdout
50 else:
51 outfp = open(sys.argv[2], 'w')
52 makeconfig(infp, outfp, sys.argv[3:])
53 if outfp != sys.stdout:
54 outfp.close()
55 if infp != sys.stdin:
56 infp.close()
57
58if __name__ == '__main__':
59 test()

Callers 1

makeconfig.pyFile · 0.70

Calls 4

makeconfigFunction · 0.85
openFunction · 0.70
exitMethod · 0.45
closeMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…