Skip to content

Commit

Permalink
Fixed multipleSchemaDepViolation test failure by swapping (#500)
Browse files Browse the repository at this point in the history
Co-authored-by: bongale2 <bongale2@illinois.edu>
  • Loading branch information
RugvedB and Rugved0103 committed Dec 15, 2023
1 parent 7dbae50 commit f69ea37
Showing 1 changed file with 6 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -143,10 +143,14 @@ public void multipleSchemaDepViolation() {
ageFailure = tmp;
}
ValidationException billingAddressFailure = creditCardFailure.getCausingExceptions().get(0);
ValidationException billingNameFailure = creditCardFailure.getCausingExceptions().get(1);
if(billingAddressFailure.getPointerToViolation().equals("#/billing_name")) {
ValidationException tmp = billingAddressFailure;
billingAddressFailure = billingNameFailure;
billingNameFailure = tmp;
}
assertEquals("#/billing_address", billingAddressFailure.getPointerToViolation());
assertEquals(billingAddressSchema, billingAddressFailure.getViolatedSchema());
ValidationException billingNameFailure = creditCardFailure
.getCausingExceptions().get(1);
assertEquals("#/billing_name", billingNameFailure.getPointerToViolation());
assertEquals(billingNameSchema, billingNameFailure.getViolatedSchema());
assertEquals("#", ageFailure.getPointerToViolation());
Expand Down

0 comments on commit f69ea37

Please sign in to comment.