Example #1
0
 public void ShouldPlotChartForAvailableStatistics()
 {
     mockPlotter.Expect("DrawGraph", new IsAnything(), new IsAnything(), new IsAnything());
     mockPlotter.ExpectNoCall("WriteToStream", typeof(IList), typeof(IList), typeof(Stream));
     chartGenerator.RelevantStats = new string[]{"TestCount"};
     chartGenerator.Process(statistics, "dummy");
 }
Example #2
0
        public void ShouldGenerateChart()
        {
            StatisticsChartGenerator generator = new StatisticsChartGenerator(new Plotter("c:/", "png", ImageFormat.Png));

            generator.RelevantStats = new string[] { "TestCount" };
            generator.Process(statistics, "dummy");
        }
Example #3
0
 public void ShouldThrowExceptionIfAskedToPlotUnavailableStatistics()
 {
     chartGenerator.RelevantStats = new string[] { "Unavailable" };
     Assert.That(delegate { chartGenerator.Process(statistics, "dummy"); }, Throws.TypeOf <UnavailableStatisticsException>());
     mockPlotter.VerifyNoOtherCalls();
 }