code: def testMultipleInstancesRetrieval(self):
      name_to_ip = [
          {"name": "instance1", "ip": "10.1.2.3"},
          {"name": "instance2", "ip": "10.2.3.4"},
          {"name": "instance3", "ip": "10.3.4.5"},
      ]
  
      gce_cluster_resolver = GCEClusterResolver(
          project="test-project",
          zone="us-east1-d",
          instance_group="test-instance-group",
          port=8470,
          credentials=None,
          service=self.gen_standard_mock_service_client(name_to_ip),
      )
  
      actual_cluster_spec = gce_cluster_resolver.cluster_spec()
      expected_proto = """
      job { name: 'worker' tasks { key: 0 value: '10.1.2.3:8470' }
                           tasks { key: 1 value: '10.2.3.4:8470' }
                           tasks { key: 2 value: '10.3.4.5:8470' } }
      """
      self._verifyClusterSpecEquality(
          actual_cluster_spec, expected_proto
      )
  
file_path: tensorflow-upstream/tensorflow/python/distribute/cluster_resolver/gce_cluster_resolver_test.py
imports: from tensorflow.python.distribute.cluster_resolver.cluster_resolver import UnionClusterResolver
  from tensorflow.python.distribute.cluster_resolver.gce_cluster_resolver import GCEClusterResolver
  from tensorflow.python.platform import test
  from tensorflow.python.training import server_lib
label_desc: Use image node_id 12 for calling the GCEClusterResolverTest obj's underlying member method code with example usage: obj.testMultipleInstancesRetrieval() without return types