code: def test_get_downstream_artifacts_by_artifact_ids(self):
      # Test: get downstream artifacts by example_1, with max_num_hops = 0
      result_from_exp1 = (
          self.resolver.get_downstream_artifacts_by_artifact_ids(
              [self.e1.id], max_num_hops=0
          )
      )
      self.assertLen(result_from_exp1, 1)
      self.assertIn(self.e1.id, result_from_exp1)
      self.assertCountEqual(
          [result_from_exp1[self.e1.id][0].name], [self.e1.name]
      )
  
      # Test: get downstream artifacts by example_1, with max_num_hops = 2
      result_from_exp1 = (
          self.resolver.get_downstream_artifacts_by_artifact_ids(
              [self.e1.id], max_num_hops=2
          )
      )
      self.assertLen(result_from_exp1, 1)
      self.assertIn(self.e1.id, result_from_exp1)
      self.assertCountEqual(
          [artifact.name for artifact in result_from_exp1[self.e1.id]],
          [self.e1.name, self.m1.name],
      )
  
      # Test: get downstream artifacts by example_1, with max_num_hops = 20
      result_from_exp1 = (
          self.resolver.get_downstream_artifacts_by_artifact_ids(
              [self.e1.id], max_num_hops=20
          )
      )
      self.assertLen(result_from_exp1, 1)
      self.assertIn(self.e1.id, result_from_exp1)
      self.assertCountEqual(
          [artifact.name for artifact in result_from_exp1[self.e1.id]],
          [self.e1.name, self.m1.name, self.ev1.name],
      )
  
      # Test: get downstream artifacts by example_1, with max_num_hops
      # unspecified.
      result_from_exp1 = (
          self.resolver.get_downstream_artifacts_by_artifact_ids(
              [self.e1.id], max_num_hops=20
          )
      )
      self.assertLen(result_from_exp1, 1)
      self.assertIn(self.e1.id, result_from_exp1)
      self.assertCountEqual(
          [artifact.name for artifact in result_from_exp1[self.e1.id]],
          [self.e1.name, self.m1.name, self.ev1.name],
      )
  
      # Test: get downstream artifacts by [example_1, example_2, example_3],
      # with max_num_hops = 20
      result_from_exp123 = (
          self.resolver.get_downstream_artifacts_by_artifact_ids(
              [self.e1.id, self.e2.id, self.e3.id], max_num_hops=20
          )
      )
      self.assertCountEqual(
          [self.e1.id, self.e2.id, self.e3.id], result_from_exp123
      )
      self.assertCountEqual(
          [
              artifact.name
              for artifact in result_from_exp123[self.e1.id]
          ],
          [self.e1.name, self.m1.name, self.ev1.name],
      )
      self.assertCountEqual(
          [
              artifact.name
              for artifact in result_from_exp123[self.e2.id]
          ],
          [self.e2.name, self.m1.name, self.m2.name, self.ev1.name],
      )
      self.assertCountEqual(
          [
              artifact.name
              for artifact in result_from_exp123[self.e3.id]
          ],
          [self.e3.name, self.m2.name, self.ev1.name],
      )
      # Test: get empty result if `artifact_ids` is empty.
      self.assertEmpty(
          self.resolver.get_downstream_artifacts_by_artifact_ids([])
      )
  
imports: from typing import Dict, List
  from absl.testing import absltest
  from ml_metadata import metadata_store
  from ml_metadata.proto import metadata_store_pb2
  from ml_metadata.tools.mlmd_resolver import metadata_resolver
  from ml_metadata.tools.mlmd_resolver import metadata_resolver_utils
label_desc: Use image node_id 2 for calling the MetadataResolverTest obj's underlying member method code with example usage: obj.test_get_downstream_artifacts_by_artifact_ids() without return types