Amazing Speedup
A library had unit tests that ran for almost 600 seconds. Two small changes dropped the run time to 26 seconds.
I was amazed.
Step 1. I turned on the cProfile. I added two methods to the slowest unit test module.
def profile(): import cProfile cProfile.run( 'main()', 'the_slow_module.prof' …more ...