This commit is contained in:
Looly
2020-09-14 21:11:32 +08:00
parent 999c1d80d4
commit ddd173a17c
2 changed files with 26 additions and 0 deletions

View File

@@ -0,0 +1,22 @@
package cn.hutool.json;
import lombok.Data;
import org.junit.Assert;
import org.junit.Test;
public class Issue1075Test {
@Test
public void test() {
String s = "{\"f1\":\"f1\",\"F2\":\"f2\",\"fac\":\"fac\"}";
ObjA o2 = JSONUtil.parseObj(s, JSONConfig.create().setIgnoreCase(true)).toBean(ObjA.class);
Assert.assertEquals("fac", o2.getFAC());
}
@Data
public static class ObjA {
private String f1;
private String F2;
private String FAC;
}
}