bipinprasad commented on a change in pull request #3215: Storm3585 - New 
compact Constraint config including maxCoLocationCnt
URL: https://github.com/apache/storm/pull/3215#discussion_r387874239
 
 

 ##########
 File path: storm-client/test/jvm/org/apache/storm/TestConfigValidate.java
 ##########
 @@ -541,6 +547,127 @@ public void testMapEntryCustomAnnotation() throws 
InvocationTargetException, NoS
         }
     }
 
+    @Test
+    public void testExactlyOneOfCustomAnnotation() throws 
InvocationTargetException, NoSuchMethodException, NoSuchFieldException,
+            InstantiationException, IllegalAccessException {
+        TestConfig config = new TestConfig();
+        Collection<Object> passCases = new LinkedList<Object>();
+        Collection<Object> failCases = new LinkedList<Object>();
+
+        List<Object> passCaseListOfList = new ArrayList<>();
+        passCaseListOfList.add(Arrays.asList("comp1", "comp2"));
+        passCaseListOfList.add(Arrays.asList("comp1", "comp3"));
+        passCaseListOfList.add(Arrays.asList("comp2", "comp4"));
+        passCaseListOfList.add(Arrays.asList("comp2", "comp5"));
+
+        Map<Object, Object> passCaseMapOfMap = new HashMap<>();
+        passCaseMapOfMap.put("comp1",
+                Stream.of(new Object[][] {
+                        { 
RasConstraintsTypeValidator.CONSTRAINT_TYPE_MAX_NODE_CO_LOCATION_CNT, 
(Integer)10 },
 
 Review comment:
   Removed superflous Integer cast

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to