Google Cloud Spanner C++ Client 2.13.0
A C++ Client Library for Google Cloud Spanner
Loading...
Searching...
No Matches
Public Member Functions | List of all members
google::cloud::spanner_mocks::MockInstanceAdminConnection Class Referenceabstract

A class to mock google::cloud::spanner::InstanceAdminConnection. More...

#include <google/cloud/spanner/mocks/mock_instance_admin_connection.h>

Public Member Functions

 MOCK_METHOD (StatusOr< google::spanner::admin::instance::v1::Instance >, GetInstance,(GetInstanceParams),(override))
 
 MOCK_METHOD (future< StatusOr< google::spanner::admin::instance::v1::Instance > >, CreateInstance,(CreateInstanceParams),(override))
 
 MOCK_METHOD (future< StatusOr< google::spanner::admin::instance::v1::Instance > >, UpdateInstance,(UpdateInstanceParams),(override))
 
 MOCK_METHOD (Status, DeleteInstance,(DeleteInstanceParams),(override))
 
 MOCK_METHOD (StatusOr< google::spanner::admin::instance::v1::InstanceConfig >, GetInstanceConfig,(GetInstanceConfigParams),(override))
 
 MOCK_METHOD (spanner::ListInstanceConfigsRange, ListInstanceConfigs,(ListInstanceConfigsParams),(override))
 
 MOCK_METHOD (spanner::ListInstancesRange, ListInstances,(ListInstancesParams),(override))
 
 MOCK_METHOD (StatusOr< google::iam::v1::Policy >, GetIamPolicy,(GetIamPolicyParams),(override))
 
 MOCK_METHOD (StatusOr< google::iam::v1::Policy >, SetIamPolicy,(SetIamPolicyParams),(override))
 
 MOCK_METHOD (StatusOr< google::iam::v1::TestIamPermissionsResponse >, TestIamPermissions,(TestIamPermissionsParams),(override))
 
virtual Options options ()
 
virtual StatusOr< google::spanner::admin::instance::v1::Instance > GetInstance (GetInstanceParams)=0
 Return the metadata for the given instance. More...
 
virtual future< StatusOr< google::spanner::admin::instance::v1::Instance > > CreateInstance (CreateInstanceParams p)=0
 
virtual future< StatusOr< google::spanner::admin::instance::v1::Instance > > UpdateInstance (UpdateInstanceParams p)=0
 
virtual Status DeleteInstance (DeleteInstanceParams p)=0
 
virtual StatusOr< google::spanner::admin::instance::v1::InstanceConfig > GetInstanceConfig (GetInstanceConfigParams)=0
 Return the InstanceConfig with the given name. More...
 
virtual ListInstanceConfigsRange ListInstanceConfigs (ListInstanceConfigsParams)=0
 Returns a one-pass input range with all the instance configs. More...
 
virtual ListInstancesRange ListInstances (ListInstancesParams params)=0
 Returns a one-pass input range with all the instances meeting the requirements in params. More...
 
virtual StatusOr< google::iam::v1::Policy > GetIamPolicy (GetIamPolicyParams)=0
 Define the interface for a google.spanner.v1.DatabaseAdmin.GetIamPolicy RPC. More...
 
virtual StatusOr< google::iam::v1::Policy > SetIamPolicy (SetIamPolicyParams)=0
 Define the interface for a google.spanner.v1.DatabaseAdmin.SetIamPolicy RPC. More...
 
virtual StatusOr< google::iam::v1::TestIamPermissionsResponse > TestIamPermissions (TestIamPermissionsParams)=0
 Define the interface for a google.spanner.v1.DatabaseAdmin.TestIamPermissions RPC. More...
 

Detailed Description

A class to mock google::cloud::spanner::InstanceAdminConnection.

Application developers may want to test their code with simulated responses, including errors from a spanner::InstanceAdminClient. To do so, construct a spanner::InstanceAdminClient with an instance of this class. Then use the Google Test framework functions to program the behavior of this mock.

Member Function Documentation

◆ CreateInstance()

virtual future< StatusOr< google::spanner::admin::instance::v1::Instance > > google::cloud::spanner::InstanceAdminConnection::CreateInstance ( CreateInstanceParams  p)
pure virtualinherited

◆ DeleteInstance()

virtual Status google::cloud::spanner::InstanceAdminConnection::DeleteInstance ( DeleteInstanceParams  p)
pure virtualinherited

◆ GetIamPolicy()

virtual StatusOr< google::iam::v1::Policy > google::cloud::spanner::InstanceAdminConnection::GetIamPolicy ( GetIamPolicyParams  )
pure virtualinherited

Define the interface for a google.spanner.v1.DatabaseAdmin.GetIamPolicy RPC.

◆ GetInstance()

virtual StatusOr< google::spanner::admin::instance::v1::Instance > google::cloud::spanner::InstanceAdminConnection::GetInstance ( GetInstanceParams  )
pure virtualinherited

Return the metadata for the given instance.

◆ GetInstanceConfig()

virtual StatusOr< google::spanner::admin::instance::v1::InstanceConfig > google::cloud::spanner::InstanceAdminConnection::GetInstanceConfig ( GetInstanceConfigParams  )
pure virtualinherited

Return the InstanceConfig with the given name.

◆ ListInstanceConfigs()

virtual ListInstanceConfigsRange google::cloud::spanner::InstanceAdminConnection::ListInstanceConfigs ( ListInstanceConfigsParams  )
pure virtualinherited

Returns a one-pass input range with all the instance configs.

◆ ListInstances()

virtual ListInstancesRange google::cloud::spanner::InstanceAdminConnection::ListInstances ( ListInstancesParams  params)
pure virtualinherited

Returns a one-pass input range with all the instances meeting the requirements in params.

◆ MOCK_METHOD() [1/10]

google::cloud::spanner_mocks::MockInstanceAdminConnection::MOCK_METHOD ( future< StatusOr< google::spanner::admin::instance::v1::Instance > >  ,
CreateInstance  ,
(CreateInstanceParams ,
(override)   
)

◆ MOCK_METHOD() [2/10]

google::cloud::spanner_mocks::MockInstanceAdminConnection::MOCK_METHOD ( future< StatusOr< google::spanner::admin::instance::v1::Instance > >  ,
UpdateInstance  ,
(UpdateInstanceParams ,
(override)   
)

◆ MOCK_METHOD() [3/10]

google::cloud::spanner_mocks::MockInstanceAdminConnection::MOCK_METHOD ( spanner::ListInstanceConfigsRange  ,
ListInstanceConfigs  ,
(ListInstanceConfigsParams ,
(override)   
)

◆ MOCK_METHOD() [4/10]

google::cloud::spanner_mocks::MockInstanceAdminConnection::MOCK_METHOD ( spanner::ListInstancesRange  ,
ListInstances  ,
(ListInstancesParams ,
(override)   
)

◆ MOCK_METHOD() [5/10]

google::cloud::spanner_mocks::MockInstanceAdminConnection::MOCK_METHOD ( Status  ,
DeleteInstance  ,
(DeleteInstanceParams ,
(override)   
)

◆ MOCK_METHOD() [6/10]

google::cloud::spanner_mocks::MockInstanceAdminConnection::MOCK_METHOD ( StatusOr< google::iam::v1::Policy >  ,
GetIamPolicy  ,
(GetIamPolicyParams ,
(override)   
)

◆ MOCK_METHOD() [7/10]

google::cloud::spanner_mocks::MockInstanceAdminConnection::MOCK_METHOD ( StatusOr< google::iam::v1::Policy >  ,
SetIamPolicy  ,
(SetIamPolicyParams ,
(override)   
)

◆ MOCK_METHOD() [8/10]

google::cloud::spanner_mocks::MockInstanceAdminConnection::MOCK_METHOD ( StatusOr< google::iam::v1::TestIamPermissionsResponse >  ,
TestIamPermissions  ,
(TestIamPermissionsParams ,
(override)   
)

◆ MOCK_METHOD() [9/10]

google::cloud::spanner_mocks::MockInstanceAdminConnection::MOCK_METHOD ( StatusOr< google::spanner::admin::instance::v1::Instance >  ,
GetInstance  ,
(GetInstanceParams ,
(override)   
)

◆ MOCK_METHOD() [10/10]

google::cloud::spanner_mocks::MockInstanceAdminConnection::MOCK_METHOD ( StatusOr< google::spanner::admin::instance::v1::InstanceConfig >  ,
GetInstanceConfig  ,
(GetInstanceConfigParams ,
(override)   
)

◆ options()

virtual Options google::cloud::spanner::InstanceAdminConnection::options ( )
inlinevirtualinherited

◆ SetIamPolicy()

virtual StatusOr< google::iam::v1::Policy > google::cloud::spanner::InstanceAdminConnection::SetIamPolicy ( SetIamPolicyParams  )
pure virtualinherited

Define the interface for a google.spanner.v1.DatabaseAdmin.SetIamPolicy RPC.

◆ TestIamPermissions()

virtual StatusOr< google::iam::v1::TestIamPermissionsResponse > google::cloud::spanner::InstanceAdminConnection::TestIamPermissions ( TestIamPermissionsParams  )
pure virtualinherited

Define the interface for a google.spanner.v1.DatabaseAdmin.TestIamPermissions RPC.

◆ UpdateInstance()

virtual future< StatusOr< google::spanner::admin::instance::v1::Instance > > google::cloud::spanner::InstanceAdminConnection::UpdateInstance ( UpdateInstanceParams  p)
pure virtualinherited