@Test
  public void testResultParsing() throws Exception {
    CMASRestResolver resolver = new CMASRestResolver(cmasBaseUrl, parser, client);

    InetSocketAddress resultAddress = resolver.resolveTarget(e.getChannel());

    assertEquals(host, resultAddress.getHostName());
    assertEquals(port, resultAddress.getPort());
  }
  @Test
  public void testBaseUrlHandlingNoTrailingDelimiter() throws Exception {
    cmasBaseUrl = "http://test";
    CMASRestResolver resolver = new CMASRestResolver(cmasBaseUrl, parser, client);

    InetSocketAddress resultAddress = resolver.resolveTarget(e.getChannel());

    verify(client).resource(cmasBaseUrl + "/uirest/vnc/registration/" + host);

    assertEquals(host, resultAddress.getHostName());
    assertEquals(port, resultAddress.getPort());
  }