Refactoring/tests.