private static List <string> VerifyWriteIndelsFile(ConcurrentDictionary <HashableIndel, int> hashables, int expected)
        {
            var indelOutcomes          = new List <string>();
            var finalIndels            = new List <string>();
            var categoryOutcomes       = new List <string>();
            var mockFactory            = new Mock <IGeminiDataOutputFactory>();
            var indelOutcomesWriter    = MockTextWriter(indelOutcomes);
            var finalIndelsWriter      = MockTextWriter(finalIndels);
            var categoryOutcomesWriter = MockTextWriter(categoryOutcomes);

            mockFactory.Setup(x => x.GetTextWriter(It.Is <string>(y => y.EndsWith("IndelOutcomes.csv"))))
            .Returns(indelOutcomesWriter.Object);
            mockFactory.Setup(x => x.GetTextWriter(It.Is <string>(y => y.EndsWith("FinalIndels.csv"))))
            .Returns(finalIndelsWriter.Object);
            mockFactory.Setup(x => x.GetTextWriter(It.Is <string>(y => y.EndsWith("CategoryOutcomes.csv"))))
            .Returns(categoryOutcomesWriter.Object);

            var outcomeWriter = new OutcomesWriter("outdir", mockFactory.Object);

            outcomeWriter.WriteIndelsFile(hashables);
            // Header only
            VerifyNumberOfLines(finalIndels, finalIndelsWriter, expected);
            VerifyNumberOfLines(indelOutcomes, indelOutcomesWriter, 0);
            VerifyNumberOfLines(categoryOutcomes, categoryOutcomesWriter, 0);
            return(finalIndels);
        }
        private static List <string> VerifyCategoryOutcomesFile(ConcurrentDictionary <string, int> tracker, int expectedLines)
        {
            var indelOutcomes          = new List <string>();
            var finalIndels            = new List <string>();
            var categoryOutcomes       = new List <string>();
            var mockFactory            = new Mock <IGeminiDataOutputFactory>();
            var indelOutcomesWriter    = MockTextWriter(indelOutcomes);
            var finalIndelsWriter      = MockTextWriter(finalIndels);
            var categoryOutcomesWriter = MockTextWriter(categoryOutcomes);

            mockFactory.Setup(x => x.GetTextWriter(It.Is <string>(y => y.EndsWith("IndelOutcomes.csv"))))
            .Returns(indelOutcomesWriter.Object);
            mockFactory.Setup(x => x.GetTextWriter(It.Is <string>(y => y.EndsWith("FinalIndels.csv"))))
            .Returns(finalIndelsWriter.Object);
            mockFactory.Setup(x => x.GetTextWriter(It.Is <string>(y => y.EndsWith("CategoryOutcomes.csv"))))
            .Returns(categoryOutcomesWriter.Object);

            var outcomeWriter = new OutcomesWriter("outdir", mockFactory.Object);

            outcomeWriter.CategorizeProgressTrackerAndWriteCategoryOutcomesFile(tracker);

            VerifyNumberOfLines(categoryOutcomes, categoryOutcomesWriter, expectedLines);
            VerifyNumberOfLines(indelOutcomes, indelOutcomesWriter, 0);
            VerifyNumberOfLines(finalIndels, finalIndelsWriter, 0);

            return(categoryOutcomes);
        }