Remove redundant modifiers
[yangtools.git] / yang / yang-data-impl / src / test / java / org / opendaylight / yangtools / yang / data / impl / schema / tree / TestModel.java
index b21dfc03f30c99beb4f418c99974cd303094b3b8..25e651914858f33fcdcf4dffbe50dcbc0e7cf9db 100644 (file)
@@ -38,14 +38,19 @@ public final class TestModel {
         throw new UnsupportedOperationException();
     }
 
-    public static final InputStream getDatastoreTestInputStream() {
+    public static InputStream getDatastoreTestInputStream() {
         return TestModel.class.getResourceAsStream(DATASTORE_TEST_YANG);
     }
 
     public static SchemaContext createTestContext() {
+        return createTestContext(DATASTORE_TEST_YANG);
+    }
+
+    public static SchemaContext createTestContext(String resourcePath) {
         YangParserImpl parser = new YangParserImpl();
         try {
-            return parser.parseSources(Collections.singleton(Resources.asByteSource(TestModel.class.getResource(DATASTORE_TEST_YANG))));
+            return parser.parseSources(Collections.singleton(Resources.asByteSource(TestModel.class
+                    .getResource(resourcePath))));
         } catch (IOException | YangSyntaxErrorException e) {
             throw new IllegalStateException("Failed to create context", e);
         }