Example #1
0
        public TestCaseGroup <TCase> ReadTestCaseGroup()
        {
            string line;

            // Reade name of group.
            string groupName = null;

            while (groupName == null)
            {
                line = this.streamReader.ReadLine();
                if (line == null)
                {
                    return(null);
                }
                if (line.Length > 0)
                {
                    groupName = line.Substring(1).TrimStart();
                }
            }

            // Read sequence of test cases within group.
            var   group = new TestCaseGroup <TCase>(groupName);
            TCase testCase;
            bool  endOfStream = false;
            bool  ignoreTestCase;

            while (!endOfStream)
            {
                testCase = ReadTestCase(out endOfStream, out ignoreTestCase);
                if (!ignoreTestCase)
                {
                    group.Add(testCase);
                }
            }
            return(group);
        }
Example #2
0
 protected override string GetKeyForItem(TestCaseGroup <TCase> item)
 {
     return(item.Name);
 }