fix(接口测试): 修复接口测试统计问题
--bug=1016909 --user=宋天阳 【接口测试】首页场景用例数量统计未执行数量不正确 https://www.tapd.cn/55049933/s/1245805
This commit is contained in:
parent
7f26b44f0e
commit
694e035cca
|
@ -249,7 +249,7 @@ public class APITestController {
|
|||
apiCountResult.setExecutionPassCount(executionPassCount);
|
||||
apiCountResult.setFakeErrorCount(fakeErrorCount);
|
||||
|
||||
if (unexecuteCount + executedCountNumber + executionPassCount > 0) {
|
||||
if (unexecuteCount + executionFailedCount + executionPassCount + fakeErrorCount > 0) {
|
||||
//通过率
|
||||
float coverageRageNumber = (float) executionPassCount * 100 / (unexecuteCount + executedCountNumber + executionPassCount);
|
||||
DecimalFormat df = new DecimalFormat("0.0");
|
||||
|
|
|
@ -184,7 +184,7 @@ public class ApiDataCountDTO {
|
|||
|
||||
public void countRunResult(List<ApiDataCountResult> countResultByRunResult) {
|
||||
for (ApiDataCountResult countResult : countResultByRunResult) {
|
||||
if (StringUtils.equalsAnyIgnoreCase(countResult.getGroupField(), "notRun", "unexecute")) {
|
||||
if (StringUtils.equalsAnyIgnoreCase(countResult.getGroupField(), "notRun", "unexecute") || StringUtils.isEmpty(countResult.getGroupField())) {
|
||||
this.unexecuteCount += countResult.getCountNumber();
|
||||
} else if ("Fail".equals(countResult.getGroupField())) {
|
||||
this.executionFailedCount += countResult.getCountNumber();
|
||||
|
|
Loading…
Reference in New Issue