code: def test_register_executions_with_stateful_working_dir_index(self):
      with self._mlmd_connection as m:
          context_type = metadata_store_pb2.ContextType(
              name="my_ctx_type"
          )
          context_type_id = m.store.put_context_type(context_type)
          context = metadata_store_pb2.Context(
              name="context", type_id=context_type_id
          )
          m.store.put_contexts([context])
  
          # Registers an execution with STATEFUL_WORKING_DIR_INDEX.
          task_gen_utils.register_executions(
              m,
              execution_type=metadata_store_pb2.ExecutionType(
                  name="my_ex_type"
              ),
              contexts=[context],
              input_and_params=[
                  task_gen_utils.InputAndParam(
                      input_artifacts={
                          "input_example": [
                              standard_artifacts.Examples()
                          ]
                      },
                      exec_properties={
                          constants.STATEFUL_WORKING_DIR_INDEX: "test_index"
                      },
                  ),
              ],
          )
  
          executions = m.store.get_executions()
          self.assertLen(executions, 1)
          self.assertEqual(
              executions[0]
              .custom_properties[constants.STATEFUL_WORKING_DIR_INDEX]
              .string_value,
              "test_index",
          )
  
imports: import os
  import time
  from unittest import mock
  import uuid
  from absl.testing import parameterized
  import tensorflow
  from tfx import types
  from tfx import version
  from tfx.orchestration import data_types_utils
  from tfx.orchestration import node_proto_view
  from tfx.orchestration.experimental.core import constants
  from tfx.orchestration.experimental.core import pipeline_state
  from tfx.orchestration.experimental.core import task
  from tfx.orchestration.experimental.core import task_gen_utils
  from tfx.orchestration.experimental.core import test_utils
  from tfx.orchestration.experimental.core.testing import test_async_pipeline
  from tfx.orchestration.experimental.core.testing import test_dynamic_exec_properties_pipeline
  from tfx.orchestration import mlmd_connection_manager
  from tfx.orchestration.portable import outputs_utils
  from tfx.orchestration.portable.mlmd import execution_lib
  from tfx.proto.orchestration import execution_result_pb2
  from tfx.proto.orchestration import placeholder_pb2
  from tfx.types import artifact_utils
  from tfx.types import standard_artifacts
  from tfx.utils import status
  from tfx.utils import test_case_utils
  from ml_metadata.proto import metadata_store_pb2
label_desc: Use image node_id 12 for calling the TaskGenUtilsTest obj's underlying member method code with example usage: obj.test_register_executions_with_stateful_working_dir_index() without return types