Controller unit testing