package iace

import "testing"

func TestBuildProposerInput_WarewashingFires(t *testing.T) {
	hazards, _, fired := BuildProposerInput(
		warewashingNarrative,
		"Gewerbliche Untertisch-Geschirrspuelmaschine (vernetzt)",
		[]string{"food_processing"},
	)
	if len(fired) == 0 || len(hazards) == 0 {
		t.Fatalf("want fired patterns + hazards, got %d patterns / %d hazards", len(fired), len(hazards))
	}
	has := func(id string) bool {
		for _, pm := range fired {
			if pm.PatternID == id {
				return true
			}
		}
		return false
	}
	if !has("HP2201") {
		t.Errorf("warewashing-specific HP2201 must fire via BuildProposerInput")
	}
}
