ctubbsii commented on code in PR #5926:
URL: https://github.com/apache/accumulo/pull/5926#discussion_r2373635321


##########
test/src/main/java/org/apache/accumulo/test/functional/ConstraintIT.java:
##########
@@ -322,6 +324,11 @@ private void test2(AccumuloClient client, String table, 
boolean doFlush) throws
               "Unexpected " + cvs.constrainClass + " " + 
cvs.numberOfViolatingMutations);
         }
       }
+
+      assertTrue(mre.getMessage().contains(
+          "constraint violation codes : 
{org.apache.accumulo.test.constraints.NumericValueConstraint=[1], 
org.apache.accumulo.test.constraints.AlphaNumKeyConstraint=[1]}")
+          || mre.getMessage().contains(
+              "constraint violation codes : 
{org.apache.accumulo.test.constraints.AlphaNumKeyConstraint=[1], 
org.apache.accumulo.test.constraints.NumericValueConstraint=[1]}"));

Review Comment:
   haha, nice... definitely easier than parsing the result... just look for 
either of the two ordering options 😺 
   
   I wish these gave different error codes, though, or if one of them had more 
violations, so we could see the set different between the two types (so, we 
could verify that constraint A had two violations, and constraint B had one, or 
had different violation codes).



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to