@Test
public void testAnnounce()
        throws Exception
{

    httpClient.setProcessor((request) -> {
        assertEquals(request.getMethod(), "PUT");
        assertEquals(request.getUri(), URI.create("v1/announcement/" + nodeInfo.getNodeId()));
        assertEquals(request.getHeader("User-Agent"), nodeInfo.getNodeId());
        assertEquals(request.getHeader("Content-Type"), "application/json");
        // TODO test request body
        return mockResponse(ACCEPTED);
    });
    Duration duration = client.announce(announcements).get();
    assertEquals(duration, new Duration(10, TimeUnit.SECONDS));
    assertEquals(httpClient.getRequestCount(), 1);
}