Package ru.vyarus.yaml.updater.update
Class CommentsParserValidator
- java.lang.Object
-
- ru.vyarus.yaml.updater.update.CommentsParserValidator
-
public final class CommentsParserValidator extends java.lang.ObjectComments parse is a very simple yaml parser and to make sure it works correctly comparing parsed structure with snakeyaml parse result (parsed trees are unified to represent equal trees).Comments parser and snakeyaml models are unified to get equally trees (easier for comparison).
During comparison, property values parsed by snakeyaml are assigned in comments tree. This is required for list items matching logic accuracy (otherwise different comments near values could prevent values matching).
- Since:
- 18.05.2021
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static voidvalidate(CmtTree comments, StructTree struct)Compare that parsed trees are structurally the same to verify comments parser correctness (assuming snakeyaml works perfectly).
-
-
-
Method Detail
-
validate
public static void validate(CmtTree comments, StructTree struct)
Compare that parsed trees are structurally the same to verify comments parser correctness (assuming snakeyaml works perfectly).- Parameters:
comments- comments parser resultstruct- snakeyaml result
-
-