Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,8 @@ public void execute(IntuitMessage intuitMessage) throws FMSException {

if ("Validation".equalsIgnoreCase(fault.getType())) {
throw new ValidationException(fault.getError());
} else if ("ValidationFault".equalsIgnoreCase(fault.getType())) {
throw new ValidationException(fault.getError());
} else if ("Service".equalsIgnoreCase(fault.getType())) {
throw new ServiceException(fault.getError());
} else if ("AuthenticationFault".equalsIgnoreCase(fault.getType())) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,23 @@ public void testHandleResponseInterceptor_Validation() {
Assert.assertTrue(isValid);
}

@Test (enabled = false)
public void testHandleResponseInterceptor_ValidationFault() {
boolean isValid = false;
IntuitResponse intuitResponse = (IntuitResponse) intuitMessage.getResponseElements().getResponse();
intuitResponse.getFault().setType("ValidationFault");
HandleResponseInterceptor interceptor = new HandleResponseInterceptor();
try {
interceptor.execute(intuitMessage);
} catch (FMSException e) {
if (e instanceof ValidationException) {
isValid = true;
}
}

Assert.assertTrue(isValid);
}

@Test (enabled = false)
public void testHandleResponseInterceptor_Service() {
boolean isValid = false;
Expand Down