fix(测试跟踪): 修复7天失败用例未统计场景列表执行时的失败次数的问题

--bug=1023470 --user=宋天阳 【测试跟踪】首页- 过去7天测试计划失败用例TOP
10,没有统计接口场景失败的次数
https://www.tapd.cn/55049933/s/1338954
This commit is contained in:
song-tianyang 2023-02-20 18:48:04 +08:00 committed by 建国
parent f45e2476f4
commit b9b018e140
1 changed files with 4 additions and 0 deletions

View File

@ -223,6 +223,10 @@ public class TestResultService {
if (planRunModes.contains(dto.getRunMode())) { if (planRunModes.contains(dto.getRunMode())) {
TestPlanApiScenario testPlanApiScenario = testPlanApiScenarioMapper.selectByPrimaryKey(scenarioReport.getScenarioId()); TestPlanApiScenario testPlanApiScenario = testPlanApiScenarioMapper.selectByPrimaryKey(scenarioReport.getScenarioId());
if (testPlanApiScenario == null) {
//测试计划-场景列表中批量/单独执行场景时关联ID记录在testID中
testPlanApiScenario = testPlanApiScenarioMapper.selectByPrimaryKey(dto.getTestId());
}
if (testPlanApiScenario != null) { if (testPlanApiScenario != null) {
ApiScenarioWithBLOBs apiScenario = apiScenarioMapper.selectByPrimaryKey(testPlanApiScenario.getApiScenarioId()); ApiScenarioWithBLOBs apiScenario = apiScenarioMapper.selectByPrimaryKey(testPlanApiScenario.getApiScenarioId());
if (apiScenario != null) { if (apiScenario != null) {