Factories and controller specs refactor