Refactoring of unit-tests