write controller spec