This commit is contained in:
Looly 2022-12-14 11:53:05 +08:00
parent e89de5c18f
commit ec4467cb43

View File

@ -0,0 +1,13 @@
package cn.hutool.json;
import org.junit.Assert;
import org.junit.Test;
public class Issue2801Test {
@Test
public void toStringTest() {
final JSONObject recordObj = new JSONObject(JSONConfig.of().setIgnoreNullValue(false));
recordObj.put("m_reportId", null);
Assert.assertEquals("{\"m_reportId\":null}", recordObj.toString());
}
}