tkalkirill commented on code in PR #892:
URL: https://github.com/apache/ignite-3/pull/892#discussion_r904905489


##########
modules/configuration/src/test/java/org/apache/ignite/internal/configuration/validation/ValidationUtilTest.java:
##########
@@ -266,12 +268,81 @@ public void validate(NamedListValidation annotation, 
ValidationContext<NamedList
         );
     }
 
+    @Test
+    void testGetOwner() {
+        var rootsNode = new SuperRoot(key -> null, 
Map.of(ValidatedRootConfiguration.KEY, root));
+
+        Validator<InnerValidation, Object> innerValidator = new Validator<>() {
+            /** {@inheritDoc} */
+            @Override
+            public void validate(InnerValidation annotation, 
ValidationContext<Object> ctx) {
+                Object oldOwner = ctx.getOldOwner();
+                Object newOwner = ctx.getOldOwner();
+
+                if (!(oldOwner instanceof ValidatedRootView)) {
+                    ctx.addIssue(new ExValidationIssue("Wrong inner owner", 
ctx.currentKey(), null, oldOwner));

Review Comment:
   Fix it



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@ignite.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to