Search in sources :

Example 1 with GrafeasSettings

use of io.grafeas.v1.GrafeasSettings in project java-containeranalysis by googleapis.

the class ITGrafeasInteropTest method createsGrafeasClient.

@Test
public void createsGrafeasClient() throws IOException {
    ContainerAnalysisClient client = ContainerAnalysisClient.create(ContainerAnalysisSettings.newBuilder().build());
    GrafeasClient grafeasClient = client.getGrafeasClient();
    ContainerAnalysisSettings settings = client.getSettings();
    GrafeasSettings grafeasSettings = grafeasClient.getSettings();
    assertEquals(settings.getClock(), grafeasSettings.getClock());
    assertEquals(settings.getBackgroundExecutorProvider(), grafeasSettings.getExecutorProvider());
    assertEquals(settings.getEndpoint(), grafeasSettings.getEndpoint());
    assertEquals(settings.getBackgroundExecutorProvider(), grafeasSettings.getExecutorProvider());
    assertEquals(settings.getHeaderProvider(), grafeasSettings.getHeaderProvider());
    assertEquals(settings.getTransportChannelProvider(), grafeasSettings.getTransportChannelProvider());
    assertEquals(settings.getWatchdogCheckInterval(), grafeasSettings.getWatchdogCheckInterval());
    assertEquals(settings.getWatchdogProvider(), grafeasSettings.getWatchdogProvider());
}
Also used : GrafeasClient(io.grafeas.v1.GrafeasClient) GrafeasSettings(io.grafeas.v1.GrafeasSettings) Test(org.junit.Test)

Aggregations

GrafeasClient (io.grafeas.v1.GrafeasClient)1 GrafeasSettings (io.grafeas.v1.GrafeasSettings)1 Test (org.junit.Test)1