class_docstr: Abstract class for integration testing concrete Metadata implementations.
  
  Subclasses should override metadata() to return an instance of Metadata that
  has not been entered.
class_docstr_tok: ["Abstract","class","for","integration","testing","concrete","Metadata","implementations",".","Subclasses","should","override","metadata","(",")","to","return","an","instance","of","Metadata","that","has","not","been","entered","."]
code: def testGetCachedOutputNoInput(self):
      with self.metadata() as m:
          # Create an 'previous' execution.
          exec_properties = {"log_root": "path"}
          contexts = m.register_pipeline_contexts_if_not_exists(
              self._pipeline_info
          )
          output_artifact = standard_artifacts.Examples()
          output_artifact.uri = "my_uri"
          output_artifacts = {"output": [output_artifact]}
          m.register_execution(
              input_artifacts={},
              exec_properties=exec_properties,
              pipeline_info=self._pipeline_info,
              component_info=self._component_info,
              contexts=contexts,
          )
          m.publish_execution(
              component_info=self._component_info,
              output_artifacts=output_artifacts,
          )
  
          cached_output_artifacts = m.get_cached_outputs(
              input_artifacts={},
              exec_properties=exec_properties,
              pipeline_info=self._pipeline_info,
              component_info=self._component_info,
          )
          self.assertEqual(len(cached_output_artifacts), 1)
          self.assertEqual(len(cached_output_artifacts["output"]), 1)
          cached_output_artifact = cached_output_artifacts["output"][
              0
          ].mlmd_artifact
          # Skip verifying time sensitive fields.
          cached_output_artifact.ClearField("type")
          cached_output_artifact.ClearField("create_time_since_epoch")
          cached_output_artifact.ClearField(
              "last_update_time_since_epoch"
          )
          self.assertProtoEquals(
              cached_output_artifact, output_artifact.mlmd_artifact
          )
  
imports: from typing import Mapping
  import tensorflow
  from tfx.orchestration import data_types
  from tfx.orchestration import metadata
  from tfx.types import artifact_utils
  from tfx.types import standard_artifacts
  from tfx.types.artifact import ArtifactState
  from ml_metadata.proto import metadata_store_pb2
label_desc: Use image node_id 12 for calling the MetadataTest obj's underlying member method code with example usage: obj.testGetCachedOutputNoInput() without return types