Class MockCloudChannelServiceConnection (2.15.1)

A class to mock CloudChannelServiceConnection.

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

See Also

This example for how to test your application with GoogleTest. While the example showcases types from the BigQuery library, the underlying principles apply for any pair of *Client and *Connection.

Functions

virtual options()

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Returns
Type Description
Options

virtual ListCustomers(google::cloud::channel::v1::ListCustomersRequest)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::ListCustomersRequest
Returns
Type Description
StreamRange< google::cloud::channel::v1::Customer >

virtual GetCustomer(google::cloud::channel::v1::GetCustomerRequest const &)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::GetCustomerRequest const &
Returns
Type Description
StatusOr< google::cloud::channel::v1::Customer >

virtual CheckCloudIdentityAccountsExist(google::cloud::channel::v1::CheckCloudIdentityAccountsExistRequest const &)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::CheckCloudIdentityAccountsExistRequest const &
Returns
Type Description
StatusOr< google::cloud::channel::v1::CheckCloudIdentityAccountsExistResponse >

virtual CreateCustomer(google::cloud::channel::v1::CreateCustomerRequest const &)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::CreateCustomerRequest const &
Returns
Type Description
StatusOr< google::cloud::channel::v1::Customer >

virtual UpdateCustomer(google::cloud::channel::v1::UpdateCustomerRequest const &)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::UpdateCustomerRequest const &
Returns
Type Description
StatusOr< google::cloud::channel::v1::Customer >

virtual DeleteCustomer(google::cloud::channel::v1::DeleteCustomerRequest const &)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::DeleteCustomerRequest const &
Returns
Type Description
Status

virtual ImportCustomer(google::cloud::channel::v1::ImportCustomerRequest const &)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::ImportCustomerRequest const &
Returns
Type Description
StatusOr< google::cloud::channel::v1::Customer >

virtual ProvisionCloudIdentity(google::cloud::channel::v1::ProvisionCloudIdentityRequest const &)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::ProvisionCloudIdentityRequest const &
Returns
Type Description
future< StatusOr< google::cloud::channel::v1::Customer > >

virtual ListEntitlements(google::cloud::channel::v1::ListEntitlementsRequest)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::ListEntitlementsRequest
Returns
Type Description
StreamRange< google::cloud::channel::v1::Entitlement >

virtual ListTransferableSkus(google::cloud::channel::v1::ListTransferableSkusRequest)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::ListTransferableSkusRequest
Returns
Type Description
StreamRange< google::cloud::channel::v1::TransferableSku >

virtual ListTransferableOffers(google::cloud::channel::v1::ListTransferableOffersRequest)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::ListTransferableOffersRequest
Returns
Type Description
StreamRange< google::cloud::channel::v1::TransferableOffer >

virtual GetEntitlement(google::cloud::channel::v1::GetEntitlementRequest const &)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::GetEntitlementRequest const &
Returns
Type Description
StatusOr< google::cloud::channel::v1::Entitlement >

virtual CreateEntitlement(google::cloud::channel::v1::CreateEntitlementRequest const &)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::CreateEntitlementRequest const &
Returns
Type Description
future< StatusOr< google::cloud::channel::v1::Entitlement > >

virtual ChangeParameters(google::cloud::channel::v1::ChangeParametersRequest const &)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::ChangeParametersRequest const &
Returns
Type Description
future< StatusOr< google::cloud::channel::v1::Entitlement > >

virtual ChangeRenewalSettings(google::cloud::channel::v1::ChangeRenewalSettingsRequest const &)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::ChangeRenewalSettingsRequest const &
Returns
Type Description
future< StatusOr< google::cloud::channel::v1::Entitlement > >

virtual ChangeOffer(google::cloud::channel::v1::ChangeOfferRequest const &)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::ChangeOfferRequest const &
Returns
Type Description
future< StatusOr< google::cloud::channel::v1::Entitlement > >

virtual StartPaidService(google::cloud::channel::v1::StartPaidServiceRequest const &)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::StartPaidServiceRequest const &
Returns
Type Description
future< StatusOr< google::cloud::channel::v1::Entitlement > >

virtual SuspendEntitlement(google::cloud::channel::v1::SuspendEntitlementRequest const &)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::SuspendEntitlementRequest const &
Returns
Type Description
future< StatusOr< google::cloud::channel::v1::Entitlement > >

virtual CancelEntitlement(google::cloud::channel::v1::CancelEntitlementRequest const &)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::CancelEntitlementRequest const &
Returns
Type Description
future< StatusOr< google::cloud::channel::v1::OperationMetadata > >

virtual ActivateEntitlement(google::cloud::channel::v1::ActivateEntitlementRequest const &)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::ActivateEntitlementRequest const &
Returns
Type Description
future< StatusOr< google::cloud::channel::v1::Entitlement > >

virtual TransferEntitlements(google::cloud::channel::v1::TransferEntitlementsRequest const &)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::TransferEntitlementsRequest const &
Returns
Type Description
future< StatusOr< google::cloud::channel::v1::TransferEntitlementsResponse > >

virtual TransferEntitlementsToGoogle(google::cloud::channel::v1::TransferEntitlementsToGoogleRequest const &)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::TransferEntitlementsToGoogleRequest const &
Returns
Type Description
future< StatusOr< google::cloud::channel::v1::OperationMetadata > >

virtual ListChannelPartnerLinks(google::cloud::channel::v1::ListChannelPartnerLinksRequest)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::ListChannelPartnerLinksRequest
Returns
Type Description
StreamRange< google::cloud::channel::v1::ChannelPartnerLink >

virtual GetChannelPartnerLink(google::cloud::channel::v1::GetChannelPartnerLinkRequest const &)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::GetChannelPartnerLinkRequest const &
Returns
Type Description
StatusOr< google::cloud::channel::v1::ChannelPartnerLink >

virtual CreateChannelPartnerLink(google::cloud::channel::v1::CreateChannelPartnerLinkRequest const &)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::CreateChannelPartnerLinkRequest const &
Returns
Type Description
StatusOr< google::cloud::channel::v1::ChannelPartnerLink >

virtual UpdateChannelPartnerLink(google::cloud::channel::v1::UpdateChannelPartnerLinkRequest const &)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::UpdateChannelPartnerLinkRequest const &
Returns
Type Description
StatusOr< google::cloud::channel::v1::ChannelPartnerLink >

virtual GetCustomerRepricingConfig(google::cloud::channel::v1::GetCustomerRepricingConfigRequest const &)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::GetCustomerRepricingConfigRequest const &
Returns
Type Description
StatusOr< google::cloud::channel::v1::CustomerRepricingConfig >

virtual ListCustomerRepricingConfigs(google::cloud::channel::v1::ListCustomerRepricingConfigsRequest)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::ListCustomerRepricingConfigsRequest
Returns
Type Description
StreamRange< google::cloud::channel::v1::CustomerRepricingConfig >

virtual CreateCustomerRepricingConfig(google::cloud::channel::v1::CreateCustomerRepricingConfigRequest const &)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::CreateCustomerRepricingConfigRequest const &
Returns
Type Description
StatusOr< google::cloud::channel::v1::CustomerRepricingConfig >

virtual UpdateCustomerRepricingConfig(google::cloud::channel::v1::UpdateCustomerRepricingConfigRequest const &)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::UpdateCustomerRepricingConfigRequest const &
Returns
Type Description
StatusOr< google::cloud::channel::v1::CustomerRepricingConfig >

virtual DeleteCustomerRepricingConfig(google::cloud::channel::v1::DeleteCustomerRepricingConfigRequest const &)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::DeleteCustomerRepricingConfigRequest const &
Returns
Type Description
Status

virtual GetChannelPartnerRepricingConfig(google::cloud::channel::v1::GetChannelPartnerRepricingConfigRequest const &)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::GetChannelPartnerRepricingConfigRequest const &
Returns
Type Description
StatusOr< google::cloud::channel::v1::ChannelPartnerRepricingConfig >

virtual ListChannelPartnerRepricingConfigs(google::cloud::channel::v1::ListChannelPartnerRepricingConfigsRequest)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::ListChannelPartnerRepricingConfigsRequest
Returns
Type Description
StreamRange< google::cloud::channel::v1::ChannelPartnerRepricingConfig >

virtual CreateChannelPartnerRepricingConfig(google::cloud::channel::v1::CreateChannelPartnerRepricingConfigRequest const &)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::CreateChannelPartnerRepricingConfigRequest const &
Returns
Type Description
StatusOr< google::cloud::channel::v1::ChannelPartnerRepricingConfig >

virtual UpdateChannelPartnerRepricingConfig(google::cloud::channel::v1::UpdateChannelPartnerRepricingConfigRequest const &)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::UpdateChannelPartnerRepricingConfigRequest const &
Returns
Type Description
StatusOr< google::cloud::channel::v1::ChannelPartnerRepricingConfig >

virtual DeleteChannelPartnerRepricingConfig(google::cloud::channel::v1::DeleteChannelPartnerRepricingConfigRequest const &)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::DeleteChannelPartnerRepricingConfigRequest const &
Returns
Type Description
Status

virtual ListSkuGroups(google::cloud::channel::v1::ListSkuGroupsRequest)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::ListSkuGroupsRequest
Returns
Type Description
StreamRange< google::cloud::channel::v1::SkuGroup >

virtual ListSkuGroupBillableSkus(google::cloud::channel::v1::ListSkuGroupBillableSkusRequest)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::ListSkuGroupBillableSkusRequest
Returns
Type Description
StreamRange< google::cloud::channel::v1::BillableSku >

virtual LookupOffer(google::cloud::channel::v1::LookupOfferRequest const &)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::LookupOfferRequest const &
Returns
Type Description
StatusOr< google::cloud::channel::v1::Offer >

virtual ListProducts(google::cloud::channel::v1::ListProductsRequest)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::ListProductsRequest
Returns
Type Description
StreamRange< google::cloud::channel::v1::Product >

virtual ListSkus(google::cloud::channel::v1::ListSkusRequest)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::ListSkusRequest
Returns
Type Description
StreamRange< google::cloud::channel::v1::Sku >

virtual ListOffers(google::cloud::channel::v1::ListOffersRequest)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::ListOffersRequest
Returns
Type Description
StreamRange< google::cloud::channel::v1::Offer >

virtual ListPurchasableSkus(google::cloud::channel::v1::ListPurchasableSkusRequest)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::ListPurchasableSkusRequest
Returns
Type Description
StreamRange< google::cloud::channel::v1::PurchasableSku >

virtual ListPurchasableOffers(google::cloud::channel::v1::ListPurchasableOffersRequest)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::ListPurchasableOffersRequest
Returns
Type Description
StreamRange< google::cloud::channel::v1::PurchasableOffer >

virtual RegisterSubscriber(google::cloud::channel::v1::RegisterSubscriberRequest const &)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::RegisterSubscriberRequest const &
Returns
Type Description
StatusOr< google::cloud::channel::v1::RegisterSubscriberResponse >

virtual UnregisterSubscriber(google::cloud::channel::v1::UnregisterSubscriberRequest const &)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::UnregisterSubscriberRequest const &
Returns
Type Description
StatusOr< google::cloud::channel::v1::UnregisterSubscriberResponse >

virtual ListSubscribers(google::cloud::channel::v1::ListSubscribersRequest)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::ListSubscribersRequest
Returns
Type Description
StreamRange< std::string >

virtual ListEntitlementChanges(google::cloud::channel::v1::ListEntitlementChangesRequest)

This function is implemented using gMock's MOCK_METHOD(). Consult the gMock documentation to use this mock in your tests.

Parameter
Name Description
request google::cloud::channel::v1::ListEntitlementChangesRequest
Returns
Type Description
StreamRange< google::cloud::channel::v1::EntitlementChange >