SPRINT PLANNING TASK, remove duplicate task requirement

This commit is contained in:
Ine Maria Nilssen Aanonsen
2026-03-17 15:26:25 +01:00
parent 9f85b1e6f8
commit 6e591fa81d

View File

@@ -152,22 +152,16 @@ func (t *SprintPlanningTask) Validate(ctx context.Context) ValidationFeedback {
top := sorted[:topN] top := sorted[:topN]
var plannedCount int var plannedCount int
var readyToSprintCount int
for _, issue := range top { for _, issue := range top {
if issue.Status == models.StatusReadyToSprint || if issue.Status == models.StatusReadyToSprint ||
issue.Status == models.StatusInProgress || issue.Status == models.StatusInProgress ||
issue.Status == models.StatusClosed { issue.Status == models.StatusClosed {
plannedCount++ plannedCount++
} }
if issue.Status == models.StatusReadyToSprint {
readyToSprintCount++
}
} }
expect.Assert(plannedCount >= 3, expect.Assert(plannedCount >= 3,
"Expected at least 3 of the 5 highest-priority issues to be moved into 'ready_to_sprint', 'in_progress', or 'closed' for the sprint.") "Expected at least 3 of the 5 highest-priority issues to be moved into 'ready_to_sprint', 'in_progress', or 'closed' for the sprint.")
expect.Assert(readyToSprintCount >= 1,
"Expected at least one of the highest-priority issues to be marked as 'ready_to_sprint' to indicate it is planned for the sprint.")
return expect.Complete() return expect.Complete()
} }