Send feedback
Class MockServiceManagerConnection (2.27.0)
Stay organized with collections
Save and categorize content based on your preferences.
Version 2.27.0 keyboard_arrow_down
A class to mock ServiceManagerConnection
.
Application developers may want to test their code with simulated responses, including errors, from an object of type ServiceManagerClient
. To do so, construct an object of type ServiceManagerClient
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 ListServices(google::api::servicemanagement::v1::ListServicesRequest)
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::api::servicemanagement::v1::ListServicesRequest
Returns
Type
Description
StreamRange< google::api::servicemanagement::v1::ManagedService >
virtual GetService(google::api::servicemanagement::v1::GetServiceRequest 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::api::servicemanagement::v1::GetServiceRequest const &
Returns
Type
Description
StatusOr< google::api::servicemanagement::v1::ManagedService >
virtual CreateService(google::longrunning::Operation const &)
This function is implemented using gMock 's MOCK_METHOD()
.
Consult the gMock documentation to use this mock in your tests.
Parameter
Name
Description
operation
google::longrunning::Operation const &
Returns
Type
Description
future< StatusOr< google::api::servicemanagement::v1::ManagedService > >
virtual DeleteService(google::longrunning::Operation const &)
This function is implemented using gMock 's MOCK_METHOD()
.
Consult the gMock documentation to use this mock in your tests.
Parameter
Name
Description
operation
google::longrunning::Operation const &
Returns
Type
Description
future< StatusOr< google::api::servicemanagement::v1::OperationMetadata > >
virtual UndeleteService(google::longrunning::Operation const &)
This function is implemented using gMock 's MOCK_METHOD()
.
Consult the gMock documentation to use this mock in your tests.
Parameter
Name
Description
operation
google::longrunning::Operation const &
Returns
Type
Description
future< StatusOr< google::api::servicemanagement::v1::UndeleteServiceResponse > >
virtual ListServiceConfigs(google::api::servicemanagement::v1::ListServiceConfigsRequest)
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::api::servicemanagement::v1::ListServiceConfigsRequest
Returns
Type
Description
StreamRange< google::api::Service >
virtual GetServiceConfig(google::api::servicemanagement::v1::GetServiceConfigRequest 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::api::servicemanagement::v1::GetServiceConfigRequest const &
Returns
Type
Description
StatusOr< google::api::Service >
virtual CreateServiceConfig(google::api::servicemanagement::v1::CreateServiceConfigRequest 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::api::servicemanagement::v1::CreateServiceConfigRequest const &
Returns
Type
Description
StatusOr< google::api::Service >
virtual SubmitConfigSource(google::longrunning::Operation const &)
This function is implemented using gMock 's MOCK_METHOD()
.
Consult the gMock documentation to use this mock in your tests.
Parameter
Name
Description
operation
google::longrunning::Operation const &
Returns
Type
Description
future< StatusOr< google::api::servicemanagement::v1::SubmitConfigSourceResponse > >
virtual ListServiceRollouts(google::api::servicemanagement::v1::ListServiceRolloutsRequest)
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::api::servicemanagement::v1::ListServiceRolloutsRequest
Returns
Type
Description
StreamRange< google::api::servicemanagement::v1::Rollout >
virtual GetServiceRollout(google::api::servicemanagement::v1::GetServiceRolloutRequest 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::api::servicemanagement::v1::GetServiceRolloutRequest const &
Returns
Type
Description
StatusOr< google::api::servicemanagement::v1::Rollout >
virtual CreateServiceRollout(google::longrunning::Operation const &)
This function is implemented using gMock 's MOCK_METHOD()
.
Consult the gMock documentation to use this mock in your tests.
Parameter
Name
Description
operation
google::longrunning::Operation const &
Returns
Type
Description
future< StatusOr< google::api::servicemanagement::v1::Rollout > >
virtual GenerateConfigReport(google::api::servicemanagement::v1::GenerateConfigReportRequest 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::api::servicemanagement::v1::GenerateConfigReportRequest const &
Returns
Type
Description
StatusOr< google::api::servicemanagement::v1::GenerateConfigReportResponse >
Send feedback
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License , and code samples are licensed under the Apache 2.0 License . For details, see the Google Developers Site Policies . Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2024-11-09 UTC.
Need to tell us more?
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2024-11-09 UTC."],[],[]]