Skip to content

Commit 2025afd

Browse files
feat(ValidatorCompare) Improve Interprete.CheckTypeTag validation
Check 2.20.2 was not possible to suppress if the entire "Interprete" tag had been removed. To address this the reference node has been changed to be: - newInterprete: when only the "Type" tag has been removed - newParam: when the entire "Interprete" tag has been removed
1 parent d40e79d commit 2025afd

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

Protocol/Tests/Protocol/Params/Param/Interprete/Type/CheckTypeTag.cs

+2-1
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,8 @@ public List<IValidationResult> Compare(MajorChangeCheckContext context)
4949

5050
if (newType == null)
5151
{
52-
results.Add(ErrorCompare.RemovedTag(newInterprete, newInterprete, newParam.Id?.RawValue));
52+
IReadable referenceNode = (IReadable)newInterprete ?? newParam;
53+
results.Add(ErrorCompare.RemovedTag(referenceNode, referenceNode, newParam.Id?.RawValue));
5354
continue;
5455
}
5556

0 commit comments

Comments
 (0)