use of io.confluent.kafkarest.entities.v2.GetTopicResponse in project kafka-rest by confluentinc.
the class TopicsResourceTest method getTopics_existingCluster_returnsTopic.
@Test
public void getTopics_existingCluster_returnsTopic() {
expect(topicManager.getTopic(TOPIC_1.getClusterId(), TOPIC_1.getName(), false)).andReturn(completedFuture(Optional.of(TOPIC_1)));
replay(topicManager);
FakeAsyncResponse response = new FakeAsyncResponse();
topicsResource.getTopic(response, TOPIC_1.getClusterId(), TOPIC_1.getName(), false);
GetTopicResponse expected = GetTopicResponse.create(newTopicData("topic-1", true, 3, 3));
assertEquals(expected, response.getValue());
}
Aggregations