Deprecate getSemanticVersion() for removal
[yangtools.git] / parser / yang-parser-rfc7950 / src / test / java / org / opendaylight / yangtools / yang / stmt / openconfigver / OpenconfigVersionBorderCaseTest.java
index 4e40aa701d6ebcc91d7ed93547cf7d22f71971b2..399e5d4cdd9c1b5e6b560edc63440dba5ee51b45 100644 (file)
@@ -23,6 +23,7 @@ import org.opendaylight.yangtools.yang.parser.api.YangParserConfiguration;
 import org.opendaylight.yangtools.yang.parser.spi.meta.ReactorException;
 import org.opendaylight.yangtools.yang.stmt.StmtTestUtils;
 
+@Deprecated(since = "8.0.4", forRemoval = true)
 public class OpenconfigVersionBorderCaseTest {
     private static final YangParserConfiguration SEMVER = YangParserConfiguration.builder()
         .importResolutionMode(ImportResolutionMode.OPENCONFIG_SEMVER)
@@ -80,7 +81,7 @@ public class OpenconfigVersionBorderCaseTest {
     public void borderCaseInvalidMajorTest() throws Exception {
         final ReactorException ex = assertThrows(ReactorException.class,
             () -> StmtTestUtils.parseYangSources("/openconfig-version/border-case/border-case-invalid-major", SEMVER));
-        assertThat(ex.getCause().getCause().getMessage(),
+        assertThat(ex.getCause().getMessage(),
             startsWith("Unable to find module compatible with requested import [bar(5.5.5)]."));
     }
 
@@ -88,7 +89,7 @@ public class OpenconfigVersionBorderCaseTest {
     public void borderCaseInvalidMinorTest() {
         final ReactorException ex = assertThrows(ReactorException.class,
             () -> StmtTestUtils.parseYangSources("/openconfig-version/border-case/border-case-invalid-minor", SEMVER));
-        assertThat(ex.getCause().getCause().getMessage(),
+        assertThat(ex.getCause().getMessage(),
             startsWith("Unable to find module compatible with requested import [bar(5.5.5)]."));
     }
 
@@ -96,7 +97,7 @@ public class OpenconfigVersionBorderCaseTest {
     public void borderCaseInvalidPatchTest() throws Exception {
         final ReactorException ex = assertThrows(ReactorException.class,
             () -> StmtTestUtils.parseYangSources("/openconfig-version/border-case/border-case-invalid-patch", SEMVER));
-        assertThat(ex.getCause().getCause().getMessage(),
+        assertThat(ex.getCause().getMessage(),
             startsWith("Unable to find module compatible with requested import [bar(5.5.5)]."));
     }
 }