Beispiel #1
0
        private void doReadTest(FileInfo file, String expTitle,
                                String expDate, String expBody)
        {
            doReadTest(2, file, expTitle, expDate, expBody);
            FileInfo categoriesFile = WriteEnwikiLineDocTask.CategoriesLineFile(file);

            doReadTest(2, categoriesFile, "Category:" + expTitle, expDate, expBody);
        }
Beispiel #2
0
        public void TestCategoryLines()
        {
            // WriteLineDocTask replaced only \t characters w/ a space, since that's its
            // separator char. However, it didn't replace newline characters, which
            // resulted in errors in LineDocSource.
            FileInfo         file    = new FileInfo(Path.Combine(getWorkDir().FullName, "two-lines-each.txt"));
            PerfRunData      runData = createPerfRunData(file, typeof(WriteLineCategoryDocMaker).AssemblyQualifiedName);
            WriteLineDocTask wldt    = new WriteEnwikiLineDocTask(runData);

            for (int i = 0; i < 4; i++)
            { // four times so that each file should have 2 lines.
                wldt.DoLogic();
            }
            wldt.Dispose();


            doReadTest(file, "title text", "date text", "body text");
        }