small refactoring in tests