Search in sources :

Example 1 with ServerInfo

use of org.apache.kafka.connect.runtime.rest.entities.ServerInfo in project kafka by apache.

the class RootResourceTest method testRootGet.

@Test
public void testRootGet() {
    EasyMock.expect(herder.kafkaClusterId()).andReturn(MockAdminClient.DEFAULT_CLUSTER_ID);
    replayAll();
    ServerInfo info = rootResource.serverInfo();
    assertEquals(AppInfoParser.getVersion(), info.version());
    assertEquals(AppInfoParser.getCommitId(), info.commit());
    assertEquals(MockAdminClient.DEFAULT_CLUSTER_ID, info.clusterId());
    verifyAll();
}
Also used : ServerInfo(org.apache.kafka.connect.runtime.rest.entities.ServerInfo) Test(org.junit.Test)

Example 2 with ServerInfo

use of org.apache.kafka.connect.runtime.rest.entities.ServerInfo in project apache-kafka-on-k8s by banzaicloud.

the class RootResourceTest method testRootGet.

@Test
public void testRootGet() {
    EasyMock.expect(herder.kafkaClusterId()).andReturn(MockAdminClient.DEFAULT_CLUSTER_ID);
    replayAll();
    ServerInfo info = rootResource.serverInfo();
    assertEquals(AppInfoParser.getVersion(), info.version());
    assertEquals(AppInfoParser.getCommitId(), info.commit());
    assertEquals(MockAdminClient.DEFAULT_CLUSTER_ID, info.clusterId());
    verifyAll();
}
Also used : ServerInfo(org.apache.kafka.connect.runtime.rest.entities.ServerInfo) Test(org.junit.Test)

Aggregations

ServerInfo (org.apache.kafka.connect.runtime.rest.entities.ServerInfo)2 Test (org.junit.Test)2