TestSendRequestListener requestListener = new TestSendRequestListener(log);
TestCloseListener closeListener = new TestCloseListener(log);
responseHandler.setConnectionListener(connectListener);
Channel channel = createClientBootstrap(responseHandler);
SocketAddress clientAddr = channel.getLocalAddress();
try
{
setListeners(responseHandler,respProcessor,requestListener,closeListener);
channel.write(new DefaultHttpRequest(HttpVersion.HTTP_1_1, HttpMethod.GET, "/test"));
//It seems that there is a race condition between the writeFuture succeeding