Some refactoring in tests ;)