fix(测试跟踪): json反序列化支持单值转数组

--bug=1018929 --user=陈建星 【测试跟踪】导入7000+用例-选择xmind格式-导入失败 https://www.tapd.cn/55049933/s/1278442
This commit is contained in:
chenjianxing 2022-10-26 16:54:24 +08:00 committed by jianxing
parent ff045f4d32
commit e2abcbafed
1 changed files with 1 additions and 0 deletions

View File

@ -26,6 +26,7 @@ public class JSON {
objectMapper.setVisibility(PropertyAccessor.FIELD, JsonAutoDetect.Visibility.ANY);
// 如果一个对象中没有任何的属性那么在序列化的时候就会报错
objectMapper.disable(SerializationFeature.FAIL_ON_EMPTY_BEANS);
objectMapper.configure(DeserializationFeature.ACCEPT_SINGLE_VALUE_AS_ARRAY, true);
}
public static String toJSONString(Object value) {