@Test
public void testFile() throws IOException, BackingStoreException {

	TestFileUtils.verifyDirectory(base, "out");
	TestFileUtils.verifyDirectory(base, "ltm");
	String in = TestFileUtils.getTestInputFile(testdataDirectory, "in", filename);
	String baseline = TestFileUtils.getTestInputFile(testdataDirectory, "baseline", filename + ".cxtm");
	File out = new File(base + File.separator + "out" + File.separator + filename + ".cxtm");
	File ltm = new File(base + File.separator + "ltm" + File.separator + filename + ".ltm");
	TestTMPrefsFactory.setFixedReference(in);
	
	runPreferencesMethods();
	
	TopicMapReferenceIF reference = TestTMPrefsFactory.getSystemTopicMapReference();
	TopicMapStoreIF store = reference.createStore(true);
	TopicMapIF topicmap = store.getTopicMap();
	
	new LTMTopicMapWriter(ltm).write(topicmap);
	new CanonicalXTMWriter(out).write(topicmap);
	// // compare results
	// Assert.assertTrue("Canonicalizing the test file " + filename +
	// 	" produces " + out + " which is different from " +
	// 	baseline, FileUtils.compareFileToResource(out, baseline));
	TestTMPrefsFactory.setFixedReference(null);
	store.close();
}