TestCase: refactoring of run()