refactor(性能测试): 增加一个response_timeout,避免目标网站不反回结果导致测试不能结束

This commit is contained in:
Captain.B 2020-09-17 14:55:08 +08:00
parent d4439f01ad
commit 10d42f432d
1 changed files with 6 additions and 0 deletions

View File

@ -439,6 +439,12 @@ public class JmeterDocumentParser implements DocumentParser {
item.appendChild(ele.getOwnerDocument().createTextNode(context.getProperty("timeout").toString()));
}
}
// 增加一个response_timeout避免目标网站不反回结果导致测试不能结束
if (item instanceof Element && nodeNameEquals(item, STRING_PROP)
&& StringUtils.equals(((Element) item).getAttribute("name"), "HTTPSampler.response_timeout")) {
removeChildren(item);
item.appendChild(ele.getOwnerDocument().createTextNode(""));
}
}
}