testing controller methods