Do not mask single exceptions
[yangtools.git] / parser / yang-parser-rfc7950 / src / test / java / org / opendaylight / yangtools / yang / stmt / DeviationResolutionTest.java
index 954b74c878ca6a8c8501db364dca1ecf0b3f8d38..648f644f36a0158fbe20cba11bb558ed403befac 100644 (file)
@@ -268,7 +268,7 @@ public class DeviationResolutionTest {
         final ReactorException ex = assertThrows(ReactorException.class, () -> TestUtils.parseYangSource(
             "/deviation-resolution-test/foo-invalid-deviation-path.yang",
             "/deviation-resolution-test/bar.yang"));
-        final Throwable cause = ex.getCause().getCause();
+        final Throwable cause = ex.getCause();
         assertThat(cause, instanceOf(InferenceException.class));
         assertThat(cause.getMessage(), startsWith(
             "Deviation target 'Absolute{qnames=[(bar?revision=2017-01-20)invalid, path]}' not found"));