tests for controller