use of com.google.devtools.clouderrorreporting.v1beta1.DeleteEventsResponse in project google-cloud-java by GoogleCloudPlatform.
the class ErrorStatsServiceClientTest method deleteEventsTest.
@Test
@SuppressWarnings("all")
public void deleteEventsTest() {
DeleteEventsResponse expectedResponse = DeleteEventsResponse.newBuilder().build();
mockErrorStatsService.addResponse(expectedResponse);
ProjectName projectName = ProjectName.create("[PROJECT]");
DeleteEventsResponse actualResponse = client.deleteEvents(projectName);
Assert.assertEquals(expectedResponse, actualResponse);
List<GeneratedMessageV3> actualRequests = mockErrorStatsService.getRequests();
Assert.assertEquals(1, actualRequests.size());
DeleteEventsRequest actualRequest = (DeleteEventsRequest) actualRequests.get(0);
Assert.assertEquals(projectName, actualRequest.getProjectNameAsProjectName());
}
Aggregations