public void AddTestClassResultAfterDisposingTestsProjectNode()
        {
            TestProjectTreeNode projectNode = (TestProjectTreeNode)rootNode;

            projectNode.Dispose();

            // Make sure the project node child nodes are
            // unaffected when the test class is removed.
            Assert.AreEqual(1, projectNode.Nodes.Count);
            TestClass testClass = projectNode.TestProject.TestClasses["MyTestFixture"];

            projectNode.TestProject.TestClasses.Remove(testClass);
            Assert.AreEqual(1, projectNode.Nodes.Count);
        }
        public void ChangeTestClassResultAfterDisposingProjectNode()
        {
            TestProjectTreeNode projectNode = (TestProjectTreeNode)rootNode;

            projectNode.Dispose();

            // Make sure the project node image index is
            // unaffected when the test class result is changed.
            Assert.AreEqual(TestTreeViewImageListIndex.TestNotRun, (TestTreeViewImageListIndex)projectNode.ImageIndex);
            TestClass testClass = projectNode.TestProject.TestClasses["MyTestFixture"];

            testClass.Result = TestResultType.Failure;
            Assert.AreEqual(TestTreeViewImageListIndex.TestNotRun, (TestTreeViewImageListIndex)projectNode.ImageIndex);
        }
        public void RemoveTestClassResultAfterDisposingTestsProjectNode()
        {
            TestProjectTreeNode projectNode = (TestProjectTreeNode)rootNode;

            projectNode.Dispose();

            // Make sure the project node child nodes are
            // unaffected when the test class is removed.
            Assert.AreEqual(1, projectNode.Nodes.Count);
            MockClass mockClass = new MockClass(projectContent, "MyNewTestClass");
            TestClass testClass = new TestClass(mockClass, testFrameworks);

            projectNode.TestProject.TestClasses.Add(testClass);
            Assert.AreEqual(1, projectNode.Nodes.Count);
        }