refactoring homepage tests