mirror of
https://gitee.com/chinabugotech/hutool.git
synced 2025-07-21 15:09:48 +08:00
add brotli support
This commit is contained in:
20
hutool-http/src/test/java/cn/hutool/http/IssueI5XBCFTest.java
Executable file
20
hutool-http/src/test/java/cn/hutool/http/IssueI5XBCFTest.java
Executable file
@@ -0,0 +1,20 @@
|
||||
package cn.hutool.http;
|
||||
|
||||
import cn.hutool.core.lang.Console;
|
||||
import org.brotli.dec.BrotliInputStream;
|
||||
import org.junit.Ignore;
|
||||
import org.junit.Test;
|
||||
|
||||
public class IssueI5XBCFTest {
|
||||
|
||||
@Test
|
||||
@Ignore
|
||||
public void getTest() {
|
||||
GlobalCompressStreamRegister.INSTANCE.register("br", BrotliInputStream.class);
|
||||
|
||||
final HttpResponse s = HttpUtil.createGet("https://static-exp1.licdn.com/sc/h/br/1cp0oqz322bdprj3qd4pojqix")
|
||||
.header(Header.ACCEPT_ENCODING, "br")
|
||||
.execute();
|
||||
Console.log(s.body());
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user