Esempio n. 1
0
        public void AddTest(TestInformation info)
        {
            TreeNode node = GetNode(info.name);

            node.ToolTipText = info.tooltip;
            node.Tag         = info;

            SetStyleBasedOnResult(node, info.result);

            AddTestResultToStatistics(info.result);
        }
Esempio n. 2
0
        private void OnTestMouseClick(object sender, TreeNodeMouseClickEventArgs clickEvent)
        {
            TreeNode clickedNode = clickEvent.Node;

            TestInformation info;

            try {
                info = ( TestInformation )clickedNode.Tag;
            } catch (InvalidCastException excpt) {
                info = new TestInformation();
            } catch (NullReferenceException excpt) {
                info = new TestInformation();
            }

            SelectTextOnFileLine(info.path, info.line, info.functionName);
        }
Esempio n. 3
0
        public void SetTestPathAndLine(TestInformation testInfo)
        {
            testInfo.name = testInfo.name.Replace('/', '.');

            TreeNode testNode = GetNode(testInfo.name);

            TestInformation info = ( TestInformation )testNode.Tag;

            info.functionName = testInfo.functionName;
            info.path         = testInfo.path;
            info.line         = testInfo.line;

            testNode.Tag = info;

            TreeNode errorNode = testNode.Nodes.Add(info.tooltip);

            SetStyleBasedOnResult(errorNode, info.result);
        }