Refactoring of MVC and a test to go with it