private void RefreshTestGroupList()
        {
            if (m_projectInfo.SelectedProject != null)
            {
                TestExecWin.SortOrder sortOrder = TestExecWin.SortOrder.None;
                switch (m_sortOrder)
                {
                case SortOrder.AS_READ_FROM_FILE:
                    sortOrder = TestExecWin.SortOrder.None;
                    break;

                case SortOrder.ALPHA:
                    sortOrder = TestExecWin.SortOrder.Ascending;
                    break;

                case SortOrder.REVERSE_ALPHA:
                    sortOrder = TestExecWin.SortOrder.Descending;
                    break;

                case SortOrder.REVERSE_READ:
                    sortOrder = TestExecWin.SortOrder.Reverse;
                    break;

                default:
                    throw new NotImplementedException();
                }

                testTreeView.Items.Clear();
                rootTestTreeViewItem = new TestTreeViewItem(null, new TestGroupEntry(true, string.Empty))
                {
                    DisplayName = "dummyRoot"
                };
                AddTestGroupEntryToTreeView(m_projectInfo.SelectedProject.TestGroups, rootTestTreeViewItem);
                rootTestTreeViewItem.TreeViewItems.First().OverallSortAllChilds(sortOrder);
                testTreeView.Items.Add(rootTestTreeViewItem.TreeViewItems.First());
            }
        }
        private void AddTestGroupEntryToTreeView(NodeList <TestGroupEntry> testGroupEntryNode, TestTreeViewItem parentTreeView)
        {
            TestTreeViewItem treeViewItem = new TestTreeViewItem(parentTreeView, testGroupEntryNode.Value)
            {
                DisplayName = testGroupEntryNode.Value.Name == string.Empty ? "<default>" : testGroupEntryNode.Value.Name
            };

            //add test functions
            foreach (var testFunc in testGroupEntryNode.Value.testFuncs)
            {
                treeViewItem.TreeViewItems.Add(new TestFunctionTreeViewItem(treeViewItem, testFunc));
            }

            //child group entries
            foreach (var childs in testGroupEntryNode.Childs)
            {
                //TODO: sort
                //Recursive call
                AddTestGroupEntryToTreeView(childs, treeViewItem);
            }

            //add to treeView
            parentTreeView.TreeViewItems.Add(treeViewItem);
        }