fix(接口测试): 修复HTTP请求form-data格式json参数的content-type未生效问题

--bug=1013787 --user=赵勇 【接口测试】post请求formdata格式同时带file和json的时候,json参数的content-type没带上 https://www.tapd.cn/55049933/s/1172914
This commit is contained in:
fit2-zhao 2022-06-02 17:29:58 +08:00 committed by f2c-ci-robot[bot]
parent 3b94459ac9
commit 1cb0965d5a
1 changed files with 0 additions and 3 deletions

View File

@ -193,9 +193,6 @@ public class MsHTTPSamplerProxy extends MsTestElement {
if (StringUtils.isNotEmpty(this.body.getType()) && "Form Data".equals(this.body.getType())) {
AtomicBoolean kvIsEmpty = new AtomicBoolean(true);
this.body.getKvs().forEach(files -> {
if (StringUtils.isNotEmpty(files.getName()) && "file".equals(files.getType()) && CollectionUtils.isNotEmpty(files.getFiles())) {
sampler.setDoBrowserCompatibleMultipart(true);
}
if (StringUtils.isNotEmpty(files.getName())) {
kvIsEmpty.set(false);
}