mirror of
https://gitee.com/chinabugotech/hutool.git
synced 2025-07-21 15:09:48 +08:00
fix code
This commit is contained in:
14
hutool-core/src/test/java/cn/hutool/core/io/BomReaderTest.java
Executable file
14
hutool-core/src/test/java/cn/hutool/core/io/BomReaderTest.java
Executable file
@@ -0,0 +1,14 @@
|
||||
package cn.hutool.core.io;
|
||||
|
||||
import cn.hutool.core.io.file.FileUtil;
|
||||
import org.junit.Assert;
|
||||
import org.junit.Test;
|
||||
|
||||
public class BomReaderTest {
|
||||
@Test
|
||||
public void readTest() {
|
||||
final BomReader bomReader = FileUtil.getBOMReader(FileUtil.file("with_bom.txt"));
|
||||
final String read = IoUtil.read(bomReader, true);
|
||||
Assert.assertEquals("此文本包含BOM头信息,用于测试BOM头读取", read);
|
||||
}
|
||||
}
|
1
hutool-core/src/test/resources/with_bom.txt
Executable file
1
hutool-core/src/test/resources/with_bom.txt
Executable file
@@ -0,0 +1 @@
|
||||
此文本包含BOM头信息,用于测试BOM头读取
|
Reference in New Issue
Block a user