def test_admin_api_connection(self, client): connection = self.mock_connection(client) admin_api.connect('', '', '') self.assertEqual(admin_api.spanner_admin_api()._connection, connection) admin_api.hangup() with self.assertRaises(error.SpannerError): admin_api.spanner_admin_api()
def test_admin_api_create_ddl_connection(self, client): connection = self.mock_connection(client) admin_api.connect('', '', '', create_ddl=['create ddl']) self.assertEqual(admin_api.spanner_admin_api()._connection, connection)