fix(db): look up caution lessons by cue

The caution action carries the vulnclass, not the finding summary.
This commit is contained in:
Coff0xc
2026-11-17 19:13:32 +00:00
parent 0fb4ed145d
commit c73fec7471
+1 -1
View File
@@ -698,7 +698,7 @@ func TestExtractLessonsRetractsAllRetests(t *testing.T) {
if _, err := d.ExtractLessonsForTask(t.Context(), task.ID); err != nil {
t.Fatal(err)
}
caution := findLessonByAction(t, d, task.ID, "caution", "Recheck", label)
caution := findLessonByAction(t, d, task.ID, "caution", "Recheck", cue)
t.Cleanup(func() { cleanupExec(t, d, `DELETE FROM rsi_lessons WHERE id=$1`, caution.ID) })
if positiveRetestEvidence(t, d, r1) != 1 {
t.Fatal("older reproduced retest lost its evidence after a later fixed retest")