Harden PromptKit upgrade integration
This commit is contained in:
@@ -202,6 +202,9 @@ func TestManifestValidateRejectsInvariants(t *testing.T) {
|
||||
{name: "successful result without passed validation", mutate: func(manifest *Manifest) { manifest.Results[0].ValidationStatus = "failed" }},
|
||||
{name: "failed result with report", mutate: func(manifest *Manifest) { manifest.Results[1].ReportPath = "02-weather-deep.md" }},
|
||||
{name: "failed result without error", mutate: func(manifest *Manifest) { manifest.Results[1].Error = nil }},
|
||||
{name: "failed passed result without repair provenance", mutate: func(manifest *Manifest) {
|
||||
manifest.Results[1].ValidationStatus = "passed"
|
||||
}},
|
||||
{name: "traversal report path", mutate: func(manifest *Manifest) { manifest.Results[0].ReportPath = "../report.md" }},
|
||||
{name: "duplicate report path", mutate: func(manifest *Manifest) {
|
||||
manifest.Results[1] = Result{Position: 2, ProfileID: "weather-deep", ModelName: "gpt-5", Status: StatusSucceeded, ValidationStatus: "passed", ReportPath: manifest.Results[0].ReportPath}
|
||||
@@ -223,6 +226,17 @@ func TestManifestValidateRejectsInvariants(t *testing.T) {
|
||||
}
|
||||
}
|
||||
|
||||
func TestManifestValidateAcceptsPostValidationFailure(t *testing.T) {
|
||||
t.Parallel()
|
||||
|
||||
manifest := validManifest()
|
||||
manifest.Results[1].ValidationStatus = "passed"
|
||||
manifest.Results[1].RepairAttempts = intPtr(0)
|
||||
if err := manifest.Validate(); err != nil {
|
||||
t.Fatalf("Manifest.Validate() rejected post-validation failure: %v", err)
|
||||
}
|
||||
}
|
||||
|
||||
func TestLogicalBundleValidate(t *testing.T) {
|
||||
t.Parallel()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user