Fix deletion of test methods after tests have been run.