code: def test_one_mapped_task_works(self, one_task_with_single_mapped_ti):
      response = self.client.get(
          "/api/v1/dags/mapped_tis/dagRuns/run_mapped_tis/taskInstances/task_2/0",
          environ_overrides={"REMOTE_USER": "test"},
      )
      assert response.status_code == 200
      response = self.client.get(
          "/api/v1/dags/mapped_tis/dagRuns/run_mapped_tis/taskInstances/task_2/1",
          environ_overrides={"REMOTE_USER": "test"},
      )
      assert response.status_code == 404
      response = self.client.get(
          "/api/v1/dags/mapped_tis/dagRuns/run_mapped_tis/taskInstances/task_2",
          environ_overrides={"REMOTE_USER": "test"},
      )
      assert response.status_code == 404
      assert response.json == {
          "detail": "Task instance is mapped, add the map_index value to the URL",
          "status": 404,
          "title": "Task instance not found",
          "type": EXCEPTIONS_LINK_MAP[404],
      }
  
imports: from __future__ import annotations
  import datetime
  import itertools
  import os
  import urllib
  import pytest
  from airflow.api_connexion.exceptions import EXCEPTIONS_LINK_MAP
  from airflow.models import TaskInstance
  from airflow.models.baseoperator import BaseOperator
  from airflow.models.dagbag import DagBag
  from airflow.models.taskmap import TaskMap
  from airflow.security import permissions
  from airflow.utils.platform import getuser
  from airflow.utils.session import provide_session
  from airflow.utils.state import State, TaskInstanceState
  from airflow.utils.timezone import datetime
  from tests.test_utils.api_connexion_utils import assert_401, create_user, delete_roles, delete_user
  from tests.test_utils.db import clear_db_runs, clear_db_sla_miss, clear_rendered_ti_fields
  from tests.test_utils.mock_operators import MockOperator
label_desc: Use image node_id 5 for calling the TestGetMappedTaskInstance obj's underlying member method code with example usage: obj.test_one_mapped_task_works(one_task_with_single_mapped_ti) without return types