fix (接口自动化): 修复执行body 数据 null 值被过滤问题 #1006210
--bug=1006210 --user=赵勇 【github#5647】接口请... https://www.tapd.cn/55049933/s/1040379
This commit is contained in:
parent
0684fe6312
commit
e7c2b28de4
|
@ -1,6 +1,7 @@
|
|||
package io.metersphere.api.dto.scenario;
|
||||
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.alibaba.fastjson.serializer.SerializerFeature;
|
||||
import io.metersphere.api.dto.scenario.request.BodyFile;
|
||||
import io.metersphere.commons.json.JSONSchemaGenerator;
|
||||
import io.metersphere.commons.utils.FileUtils;
|
||||
|
@ -89,7 +90,7 @@ public class Body {
|
|||
try {
|
||||
JSONObject jsonObject = com.alibaba.fastjson.JSON.parseObject(this.getRaw());
|
||||
jsonMockParse(jsonObject);
|
||||
this.raw = JSONObject.toJSONString(jsonObject);
|
||||
this.raw = JSONObject.toJSONString(jsonObject, SerializerFeature.WriteMapNullValue);
|
||||
} catch (Exception e) {}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue