public void Test02_DocumentStatistics_SUPPORTED_BUT_NOT_WORKING() { System.IO.File.Delete(TEST_OUTPUT_FOLDER + "dirty.doc"); string fileName = TEST_FOLDER + "dirty.doc"; IFile file = new File(fileName, "dirty.doc"); Assert.IsTrue(DoesFileHaveMetdata(file, "DocumentStatistic")); file.Dispose(); CleanerController cleaner = new CleanerController(); cleaner.Options.UnCheckAll(); cleaner.Options["DocumentStatistics"].Checked = true; cleaner.WriteToFolder = TEST_OUTPUT_FOLDER; cleaner.Files.AddRange(new string[] { fileName }, false); cleaner.Process(); file = new File(TEST_OUTPUT_FOLDER + "dirty.doc", "dirty.doc"); Assert.IsFalse(DoesFileHaveMetdata(file, "DocumentStatistic")); System.IO.File.Delete(TEST_OUTPUT_FOLDER + "dirty.doc"); }
public void Test01_Footnotes_SUPPORTED() { System.IO.File.Delete(TEST_OUTPUT_FOLDER + "footnotes.doc"); string fileName = TEST_FOLDER + "footnotes.doc"; IFile file = new File(fileName, "footnotes.doc"); Assert.IsTrue(DoesFileHaveMetdata(file, "Footnote")); file.Dispose(); CleanerController cleaner = new CleanerController(); cleaner.Options.UnCheckAll(); cleaner.Options["Footnotes"].Checked = true; cleaner.WriteToFolder = TEST_OUTPUT_FOLDER; cleaner.Files.AddRange(new string[]{fileName}, false); cleaner.Process(); file = new File(TEST_OUTPUT_FOLDER + "footnotes.doc", "footnotes.doc"); Assert.IsFalse(DoesFileHaveMetdata(file, "Footnote")); System.IO.File.Delete(TEST_OUTPUT_FOLDER + "footnotes.doc"); }
public void Test04_Headers_NOTAPPLICABLE() { System.IO.File.Delete(TEST_OUTPUT_FOLDER + "headers.docx"); string fileName = TEST_FOLDER + "headers.docx"; IFile file = new File(fileName, "headers.docx"); Assert.IsTrue(DoesFileHaveMetdata(file, "Header")); file.Dispose(); CleanerController cleaner = new CleanerController(); cleaner.Options.UnCheckAll(); cleaner.Options["Headers"].Checked = true; cleaner.WriteToFolder = TEST_OUTPUT_FOLDER; cleaner.Files.AddRange(new string[]{fileName}, false); cleaner.Process(); file = new File(TEST_OUTPUT_FOLDER + "headers.docx", "headers.docx"); Assert.IsTrue(DoesFileHaveMetdata(file, "Header")); System.IO.File.Delete(TEST_OUTPUT_FOLDER + "headers.docx"); }
public void Test20_HiddenText_SUPPORTED() { System.IO.File.Delete(TEST_OUTPUT_FOLDER + "HiddenText.rtf"); string fileName = TEST_FOLDER + "HiddenText.rtf"; IFile file = new File(fileName, "HiddenText.rtf"); Assert.IsTrue(DoesFileHaveMetadata(file, "HiddenText")); file.Dispose(); CleanerController cleaner = new CleanerController(); cleaner.Options.UnCheckAll(); cleaner.Options["HiddenText"].Checked = true; cleaner.WriteToFolder = TEST_OUTPUT_FOLDER; cleaner.Files.AddRange(new string[]{fileName}, false); cleaner.Process(); file = new File(TEST_OUTPUT_FOLDER + "HiddenText.rtf", "HiddenText.rtf"); Assert.IsFalse(DoesFileHaveMetadata(file, "HiddenText")); System.IO.File.Delete(TEST_OUTPUT_FOLDER + "HiddenText.rtf"); }