예제 #1
0
        public void VisualizationCanGetVisualizerAsService()
        {
            TestableVisualizer visualizer = CreateVisualizer();

            MockVisualization visualization = visualizer.AddNewVisualization <MockVisualization>();

            Assert.AreSame(visualizer, visualization.Visualizer);
        }
예제 #2
0
        TestableVisualizer CreateVisualizer()
        {
            TestableRootWorkItem wi         = new TestableRootWorkItem();
            TestableVisualizer   visualizer = new TestableVisualizer();

            visualizer.Initialize(wi, wi.Builder);

            return(visualizer);
        }
예제 #3
0
        public void VisualizerLoadsVisualizationsFromConfiguration()
        {
            TestableRootWorkItem wi         = new TestableRootWorkItem();
            TestableVisualizer   visualizer = new TestableVisualizer();

            visualizer.AddVisualizersFromConfig = true;
            visualizer.Initialize(wi, wi.Builder);

            Assert.AreEqual(1, visualizer.Visualizations.Count);
            foreach (object vis in visualizer.Visualizations)
            {
                Assert.IsTrue(vis is MockVisualization);
            }
        }