Finalize structured diagnostic aggregation
This commit is contained in:
@@ -310,10 +310,10 @@ func TestExtractAppliesSceneEligibilityBeforePromptConstruction(t *testing.T) {
|
||||
t.Fatal("CombatTurns = nil, want accepted non-nil empty list")
|
||||
}
|
||||
if test.wantWarning != "" {
|
||||
if len(result.Warnings) != 0 || len(result.Diagnostics) != 1 || result.Diagnostics[0].Samples[0].Scope != SceneDescriptionReferenceSlot || result.Diagnostics[0].ReasonCode != test.wantWarning || result.Diagnostics[0].Disposition != contracts.DiagnosticDispositionWarning || result.Diagnostics[0].Category != contracts.DiagnosticCategoryDegradation {
|
||||
if len(result.Diagnostics) != 1 || result.Diagnostics[0].Samples[0].Scope != SceneDescriptionReferenceSlot || result.Diagnostics[0].ReasonCode != test.wantWarning || result.Diagnostics[0].Disposition != contracts.DiagnosticDispositionWarning || result.Diagnostics[0].Category != contracts.DiagnosticCategoryDegradation {
|
||||
t.Fatalf("diagnostics = %#v", result.Diagnostics)
|
||||
}
|
||||
} else if len(result.Warnings) != 0 || len(result.Diagnostics) != 0 {
|
||||
} else if len(result.Diagnostics) != 0 {
|
||||
t.Fatalf("diagnostics = %#v, want none", result.Diagnostics)
|
||||
}
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user