Class MockTopicAdminConnection (2.21.0)

A googlemock-based mock for pubsub::TopicAdminConnection.

Functions

virtual CreateTopic(CreateTopicParams)

Defines the interface for TopicAdminClient::CreateTopic()

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

Parameter
NameDescription
CreateTopicParams
Returns
TypeDescription
StatusOr< google::pubsub::v1::Topic >

virtual GetTopic(GetTopicParams)

Defines the interface for TopicAdminClient::GetTopic()

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

Parameter
NameDescription
GetTopicParams
Returns
TypeDescription
StatusOr< google::pubsub::v1::Topic >

virtual UpdateTopic(UpdateTopicParams)

Defines the interface for TopicAdminClient::UpdateTopic()

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

Parameter
NameDescription
UpdateTopicParams
Returns
TypeDescription
StatusOr< google::pubsub::v1::Topic >

virtual ListTopics(ListTopicsParams)

Defines the interface for TopicAdminClient::ListTopics()

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

Parameter
NameDescription
ListTopicsParams
Returns
TypeDescription
ListTopicsRange

virtual DeleteTopic(DeleteTopicParams)

Defines the interface for TopicAdminClient::DeleteTopic()

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

Parameter
NameDescription
DeleteTopicParams
Returns
TypeDescription
Status

virtual DetachSubscription(DetachSubscriptionParams)

Defines the interface for TopicAdminClient::DetachSubscriptions()

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

Parameter
NameDescription
DetachSubscriptionParams
Returns
TypeDescription
StatusOr< google::pubsub::v1::DetachSubscriptionResponse >

virtual ListTopicSubscriptions(ListTopicSubscriptionsParams)

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

Parameter
NameDescription
ListTopicSubscriptionsParams
Returns
TypeDescription
ListTopicSubscriptionsRange

virtual ListTopicSnapshots(ListTopicSnapshotsParams)

Defines the interface for TopicAdminClient::ListTopicSnapshots()

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

Parameter
NameDescription
ListTopicSnapshotsParams
Returns
TypeDescription
ListTopicSnapshotsRange

virtual options() const

Returns the options used to create the connection.

Returns
TypeDescription
Options