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

Function runTests

Lib/test/test_unittest/test_runner.py:35–49  ·  view source on GitHub ↗
(*cases)

Source from the content-addressed store, hash-verified

33
34
35def runTests(*cases):
36 suite = unittest.TestSuite()
37 for case in cases:
38 tests = unittest.defaultTestLoader.loadTestsFromTestCase(case)
39 suite.addTests(tests)
40
41 runner = getRunner()
42
43 # creating a nested suite exposes some potential bugs
44 realSuite = unittest.TestSuite()
45 realSuite.addTest(suite)
46 # adding empty suites to the end exposes potential bugs
47 suite.addTest(unittest.TestSuite())
48 realSuite.addTest(unittest.TestSuite())
49 return runner.run(realSuite)
50
51
52def cleanup(ordering, blowUp=False):

Calls 5

getRunnerFunction · 0.85
loadTestsFromTestCaseMethod · 0.80
addTestsMethod · 0.80
addTestMethod · 0.80
runMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…