Skip to content

Commit

Permalink
fix: block plan production when no case found (#349)
Browse files Browse the repository at this point in the history
  • Loading branch information
QizhengMo authored Aug 22, 2024
1 parent e187235 commit 9df9587
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
4 changes: 2 additions & 2 deletions arex-schedule-web-api/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@
<parent>
<artifactId>arex-schedule-parent</artifactId>
<groupId>com.arextest</groupId>
<version>1.2.14</version>
<version>1.2.15</version>
</parent>

<profiles>
Expand Down Expand Up @@ -338,5 +338,5 @@
</properties>
</profile>
</profiles>
<version>1.2.14</version>
<version>1.2.15</version>
</project>
Original file line number Diff line number Diff line change
Expand Up @@ -459,13 +459,14 @@ private Pair<ReplayPlan, CommonResponse> buildReplayPlan(BuildReplayPlanRequest
return Pair.of(null, CommonResponse.badResponse("save replay action error, " + replayPlan,
new BuildReplayPlanResponse(BuildReplayFailReasonEnum.DB_ERROR)));
}
progressEvent.onReplayPlanCreated(replayPlan);

planConsumePrepareService.preparePlan(replayPlan);
if (replayPlan.getCaseTotalCount() == 0) {
return Pair.of(null, CommonResponse.badResponse("No case found in selected range"));
}

progressEvent.onReplayPlanCreated(replayPlan);

replayPlan.setExecutionContexts(planExecutionContextProvider.buildContext(replayPlan));
if (CollectionUtils.isEmpty(replayPlan.getExecutionContexts())) {
replayPlan.setErrorMessage("Got empty execution context");
Expand Down
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -320,5 +320,5 @@
<url>https://github.com/arextest/arex-replay-schedule</url>
</scm>
<url>https://github.com/arextest/arex-replay-schedule</url>
<version>1.2.14</version>
<version>1.2.15</version>
</project>

0 comments on commit 9df9587

Please sign in to comment.