Refactor some cmd_info tests