Use native configuration validation and diagnostics

This commit is contained in:
2026-11-20 15:22:57 +00:00
parent 7e45ffca43
commit 39b4bddbc9
47 changed files with 351 additions and 308 deletions

View File

@@ -39,7 +39,7 @@ inputs:
audio_dir: ./audio
`)
_, err := Load(pipelinePath, sessionPath)
if err == nil || !strings.Contains(err.Error(), "strict decode failed") {
if err == nil || !strings.Contains(configurationErrorText(err), "decode.unknown_field") {
t.Fatalf("Load() error = %v, want strict decode failed", err)
}
}
@@ -55,7 +55,7 @@ inputs:
audio_dir: ./audio
`)
_, err := Load(pipelinePath, sessionPath)
if err == nil || !strings.Contains(err.Error(), "pipeline.cache.root is required") {
if err == nil || !strings.Contains(configurationErrorText(err), "pipeline.cache.root is required") {
t.Fatalf("Load() error = %v, want cache root error", err)
}
}