Refactor router controller unit tests