This commit is contained in:
Looly
2020-11-16 20:18:53 +08:00
parent b268ddb540
commit aff16c283c
6 changed files with 44 additions and 29 deletions

View File

@@ -526,4 +526,13 @@ public class JSONObjectTest {
// 集合类不支持转为JSONObject
new JSONObject(new JSONArray(), JSONConfig.create());
}
@Test
public void floatTest(){
Map<String, Object> map = new HashMap<>();
map.put("c", 2.0F);
final String s = JSONUtil.toJsonStr(map);
Console.log(s);
}
}