  def testGetNetwork(self, mock_gce_api):
    """Test getting the network API object."""
    networks_mock = mock_gce_api.return_value.networks.return_value
    networks_mock.get.return_value.execute.return_value = gcp_mocks.MOCK_COMPUTE_NETWORK
    network_name = 'fake_network'
    compute_network = gcp_mocks.FAKE_ANALYSIS_PROJECT.compute.GetNetwork(network_name)
    self.assertEqual(network_name, compute_network.get('name'))
    networks_mock.get.assert_called()
Test getting the network API object.
tests/providers/gcp/internal/test_compute.py