if (testUrl == null) {
int port = EnvTestUtil.getFreePort();
jettyServer = new Server(port);
Context jettyContext = new Context(jettyServer, "/");
ServletHolder holder = new ServletHolder(new AgentServlet());
holder.setInitParameter("dispatcherClasses", "org.jolokia.jsr160.Jsr160RequestDispatcher");
jettyContext.addServlet(holder, "/j4p/*");
SecurityHandler securityHandler = createSecurityHandler();
jettyContext.addHandler(securityHandler);