We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
This is the test case to show the problem, most of it is copied from WebResponseDataTest:
@Test public void testWebResponse() throws Exception { final InputStream stream = getClass().getClassLoader().getResourceAsStream("testfiles/test.html.brotli"); final byte[] zippedContent = IOUtils.toByteArray(stream); final List<com.gargoylesoftware.htmlunit.util.NameValuePair> headers = new ArrayList<>(); headers.add(new com.gargoylesoftware.htmlunit.util.NameValuePair("Content-Encoding", "br")); final WebResponseData data = new WebResponseData(zippedContent, HttpStatus.SC_OK, "OK", headers); WebResponse response=new WebResponse(data,new URL("http://test.com"),HttpMethod.GET,1000); logger.info("content string:{}", response.getContentAsString()); logger.info("body:{}", new String(data.getBody(), UTF_8)); }
Just compare the output of the last 2 lines.
The text was updated successfully, but these errors were encountered:
9d5c33b
No branches or pull requests
This is the test case to show the problem, most of it is copied from WebResponseDataTest:
Just compare the output of the last 2 lines.
The text was updated successfully, but these errors were encountered: