public void WriteResults(Stream s, ParsedData parsedData)
        {
            IWorkbook workbook = new XSSFWorkbook();

            if (parsedData.ResultLines.Count() > 0)
            {
                var trsumWriter = new XLSXTestResultSummarySheetWriter(workbook.CreateSheet("TestResults - Summary"));
                trsumWriter.CreateSheet(yellowBand, greenBand, parsedData);

                var trWriter = new XLSXTestResultSheetWriter(workbook.CreateSheet("TestResults"));
                trWriter.CreateSheet(yellowBand, greenBand, parsedData);
            }

            if (parsedData.NCrunchCoverageData.Count() > 0)
            {
                var ncsumWriter = new XLSXNCrunchCoverageSummarySheetWriter(workbook.CreateSheet("NCrunch Coverage - Summary"));
                ncsumWriter.CreateSheet(yellowBand, greenBand, parsedData.NCrunchCoverageData);

                var ncWriter = new XLSXNCrunchCoverageSheetWriter(workbook.CreateSheet("NCrunch Coverage"));
                ncWriter.CreateSheet(yellowBand, greenBand, parsedData.NCrunchCoverageData);
            }

            workbook.Write(s);
        }
Exemple #2
0
        public void WriteResults(Stream s, ParsedData parsedData)
        {
            IWorkbook workbook = new XSSFWorkbook();

            if (parsedData.ResultLines.Count() > 0)
            {
                var trsumWriter = new XLSXTestResultSummarySheetWriter(workbook.CreateSheet("TestResults - Summary"));
                trsumWriter.CreateSheet(yellowBand, greenBand, parsedData);

                var trWriter = new XLSXTestResultSheetWriter(workbook.CreateSheet("TestResults"));
                trWriter.CreateSheet(yellowBand, greenBand, parsedData);
            }

            if (parsedData.NCrunchCoverageData.Count() > 0)
            {
                var ncsumWriter = new XLSXNCrunchCoverageSummarySheetWriter(workbook.CreateSheet("NCrunch Coverage - Summary"));
                ncsumWriter.CreateSheet(yellowBand, greenBand, parsedData.NCrunchCoverageData);

                var ncWriter = new XLSXNCrunchCoverageSheetWriter(workbook.CreateSheet("NCrunch Coverage"));
                ncWriter.CreateSheet(yellowBand, greenBand, parsedData.NCrunchCoverageData);
            }

            workbook.Write(s);
        }