fix(m9/T32b): resolve $ref in InboundAPI runtime validators (no deploy-passes/runtime-400); diamond test; ref-annotation message
This commit is contained in:
@@ -186,10 +186,15 @@ public class ValidationService
|
||||
return;
|
||||
}
|
||||
|
||||
foreach (var missing in parsed.UnresolvedRefs)
|
||||
foreach (var missing in parsed.UnresolvedReferences)
|
||||
{
|
||||
// Keep the lib:-qualified pointer name SEPARATE from the diagnostic
|
||||
// reason so the message reads "schema 'lib:Foo' could not be resolved
|
||||
// (cyclic reference)" rather than embedding the annotation inside the
|
||||
// lib:-looking string (M9-T32b code-review MINOR).
|
||||
var reasonSuffix = missing.Reason is null ? string.Empty : $" ({missing.Reason})";
|
||||
errors.Add(ValidationEntry.Error(ValidationCategory.SchemaReference,
|
||||
$"Script '{scriptName}' {schemaLabel} references schema 'lib:{missing}' which could not be resolved.",
|
||||
$"Script '{scriptName}' {schemaLabel} references schema 'lib:{missing.Name}' which could not be resolved{reasonSuffix}.",
|
||||
scriptName));
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user