Refactorings in tests.