public static void transferTestInputDirectory(String directory, boolean searchSubdirectories) throws IOException { transferTestInputDirectory(new ResourcesDirectoryReader(testdataInputRoot + directory, searchSubdirectories), directory); }
public static void transferTestInputDirectory(String directory, boolean searchSubdirectories, String filter) throws IOException { transferTestInputDirectory(new ResourcesDirectoryReader(testdataInputRoot + directory, searchSubdirectories, filter), directory); }
public static void transferTestInputDirectory(String directory, boolean searchSubdirectories, ResourcesFilterIF filter) throws IOException { transferTestInputDirectory(new ResourcesDirectoryReader(testdataInputRoot + directory, searchSubdirectories, filter), directory); }
public static void transferTestInputDirectory(String directory) throws IOException { transferTestInputDirectory(new ResourcesDirectoryReader(testdataInputRoot + directory), directory); }
@Test public void testReadFromInputSource() throws IOException { TestFileUtils.transferTestInputDirectory("various"); File file = TestFileUtils.getTransferredTestInputFile("various", "jill.xtm"); TopicMapIF tm = new XTMTopicMapReader(new InputSource(new FileReader(file)), new URILocator(file)).read(); Assert.assertNotNull(tm); Assert.assertEquals(39, tm.getTopics().size()); }
@Test public void testReadFromInputStream() throws IOException { TestFileUtils.transferTestInputDirectory("various"); File file = TestFileUtils.getTransferredTestInputFile("various", "jill.xtm"); TopicMapIF tm = new XTMTopicMapReader(new FileInputStream(file), new URILocator(file)).read(); Assert.assertNotNull(tm); Assert.assertEquals(39, tm.getTopics().size()); }
@Test public void testReadFromReader() throws IOException { TestFileUtils.transferTestInputDirectory("various"); File file = TestFileUtils.getTransferredTestInputFile("various", "jill.xtm"); TopicMapIF tm = new XTMTopicMapReader(new FileReader(file), new URILocator(file)).read(); Assert.assertNotNull(tm); Assert.assertEquals(39, tm.getTopics().size()); }
@Test public void testReadFromFile() throws IOException { TestFileUtils.transferTestInputDirectory("various"); TopicMapIF tm = new XTMTopicMapReader(TestFileUtils.getTransferredTestInputFile("various", "jill.xtm")).read(); Assert.assertNotNull(tm); Assert.assertEquals(39, tm.getTopics().size()); }