Thread.currentThread().setContextClassLoader(myClassLoader);
// END of workaround; The entire block can be removed after grizzly is migrated to more recent version
final ResourceConfig resourceConfig = createResourceConfig();
final HttpServer server = GrizzlyHttpServerFactory.createHttpServer(baseUri, resourceConfig);
final Client client = ClientBuilder.newClient();
String wadl = client.target(baseUri).path("items").queryParam(WadlUtils.DETAILED_WADL_QUERY_PARAM, "true")
.request(MediaTypes.WADL).options(String.class);
assertTrue("Generated wadl is of null length", wadl.length() > 0);
assertTrue("Generated wadl doesn't contain the expected text",
wadl.contains("This is a paragraph"));
checkWadl(wadl, baseUri);
server.shutdownNow();
}