BUG-4688: eliminate SimpleDateFormatUtil.DEFAULT_DATE_REV
[yangtools.git] / yang / yang-data-impl / src / test / java / org / opendaylight / yangtools / yang / data / impl / schema / tree / OrderedListTest.java
index 41dcc93a39c8956625a582361eb206b396d48513..003a1028da7dcc7e208af65cd97eb77125b1be94 100644 (file)
@@ -13,14 +13,12 @@ import static org.junit.Assert.assertTrue;
 import static org.junit.Assert.fail;
 
 import com.google.common.collect.ImmutableMap;
-import java.io.File;
 import java.net.URI;
 import java.util.Optional;
 import org.junit.Before;
 import org.junit.Test;
 import org.opendaylight.yangtools.yang.common.QName;
 import org.opendaylight.yangtools.yang.common.QNameModule;
-import org.opendaylight.yangtools.yang.common.SimpleDateFormatUtil;
 import org.opendaylight.yangtools.yang.data.api.YangInstanceIdentifier;
 import org.opendaylight.yangtools.yang.data.api.YangInstanceIdentifier.NodeIdentifier;
 import org.opendaylight.yangtools.yang.data.api.YangInstanceIdentifier.NodeIdentifierWithPredicates;
@@ -57,12 +55,9 @@ public class OrderedListTest {
     private QName childOrdinaryLeaf;
 
     @Before
-    public void setup() throws Exception {
-        final File resourceFile = new File(Bug4295Test.class.getResource("/ordered-list-modification-test.yang")
-                .toURI());
-        context = YangParserTestUtils.parseYangFiles(resourceFile);
-        testModule = QNameModule.create(new URI("ordered-list-modification-test"),
-                SimpleDateFormatUtil.getRevisionFormat().parse("1970-01-01"));
+    public void setup() {
+        context = YangParserTestUtils.parseYangResource("/ordered-list-modification-test.yang");
+        testModule = QNameModule.create(URI.create("ordered-list-modification-test"), null);
         parentContainer = QName.create(testModule, "parent-container");
         childContainer = QName.create(testModule, "child-container");
         parentOrderedList = QName.create(testModule, "parent-ordered-list");