Update the matched values control test case to replace a couple of calls to
catch Exception with catch Throwable. This is necessary because when
assertions are enabled when running the unit tests, an AssertionError will be
generated by the methods in the Validator class rather than an exception, and
Throwable covers both exceptions and errors whereas Exception doesn't handle
errors.
| | |
| | | } |
| | | } |
| | | } |
| | | catch (Exception e) |
| | | catch (Throwable t) |
| | | { |
| | | if ( ! exceptionExpected) |
| | | { |
| | | assertTrue(false, "Exception not excepted: " + e.getMessage()); |
| | | assertTrue(false, "Exception not excepted: " + t.getMessage()); |
| | | } |
| | | } |
| | | } |
| | |
| | | assertEquals(attValueTestCurrent, mvf.getAssertionValue()); |
| | | } |
| | | } |
| | | catch (Exception e) |
| | | catch (Throwable t) |
| | | { |
| | | if ( ! exceptionExpected) |
| | | { |
| | | assertTrue(false, "Exception not excepted" + e.getMessage()); |
| | | assertTrue(false, "Exception not excepted" + t.getMessage()); |
| | | } |
| | | } |
| | | } |