MCPcopy Create free account
hub / github.com/RT-Thread/env-windows / test

Function test

tools/python-3.11.9-amd64/Lib/imghdr.py:138–151  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

136#--------------------#
137
138def test():
139 import sys
140 recursive = 0
141 if sys.argv[1:] and sys.argv[1] == '-r':
142 del sys.argv[1:2]
143 recursive = 1
144 try:
145 if sys.argv[1:]:
146 testall(sys.argv[1:], recursive, 1)
147 else:
148 testall(['.'], recursive, 1)
149 except KeyboardInterrupt:
150 sys.stderr.write('\n[Interrupted]\n')
151 sys.exit(1)
152
153def testall(list, recursive, toplevel):
154 import sys

Callers 1

imghdr.pyFile · 0.70

Calls 3

testallFunction · 0.70
writeMethod · 0.45
exitMethod · 0.45

Tested by

no test coverage detected