def METHOD_NAME(self, unit: "Unit", agent: "Agent"):
    """
    Mock runners will pass the agents for the given assignment
    all of the required messages to finish a task.
    """
    self.tracked_tasks[unit.db_id] = unit
    time.sleep(0.3)
    assigned_agent = unit.get_assigned_agent()
    assert assigned_agent is not None, "No agent was assigned"
    assert assigned_agent.db_id == agent.db_id, "Task was not given to assigned agent"
    packet = agent.get_live_update(timeout=self.timeout)
    if packet is not None:
        agent.observe(packet)
    agent.await_submit(self.args.task.submission_timeout)
    del self.tracked_tasks[unit.db_id]