use of com.google.cloud.dialogflow.cx.v3.TestCasesSettings in project java-dialogflow-cx by googleapis.
the class ListTestCaseResults method listTestCaseResults.
public static void listTestCaseResults(String projectId, String agentId, String testId, String location) throws IOException {
String parent = "projects/" + projectId + "/locations/" + location + "/agents/" + agentId + "/testCases/" + testId;
Builder req = ListTestCaseResultsRequest.newBuilder();
req.setParent(parent);
req.setFilter("environment=draft");
TestCasesSettings testCasesSettings = TestCasesSettings.newBuilder().setEndpoint(location + "-dialogflow.googleapis.com:443").build();
TestCasesClient client = TestCasesClient.create(testCasesSettings);
for (TestCaseResult element : client.listTestCaseResults(req.build()).iterateAll()) {
System.out.println(element);
}
}
Aggregations