示例#1
0
        public void AppendCopyOfTestCaseTest(int idx, int conditionCount, int actionCount, int testCasesCount)
        {
            TestCasesRoot tcr = TestCasesRoot.CreateSimpleTable2(conditionCount, actionCount, testCasesCount);

            TestUtils.CheckTestCasesAndConditionsAndActions(tcr);

            for (int tcIdx = 0; tcIdx < testCasesCount; tcIdx++)
            {
                TestCase newTestCase      = tcr.InsertTestCase();
                TestCase templateTestCase = tcr.TestCases[tcIdx];
                tcr.CopyTestCaseSettings(templateTestCase, newTestCase);
            }

            // create and save the sample project
            string savePath = Path.Combine(TestSupport.CreatedFilesDirectory, idx + "SimpleProject.dtc");

            tcr.Save(savePath);
            //ProcessStartInfo info = new ProcessStartInfo(@"C:\Program Files (x86)\Notepad++\notepad++.exe", savePath);
            //Process.Start(info);

            for (int tcIdx = 0; tcIdx < testCasesCount; tcIdx++)
            {
                CompareTestCases(tcr, tcIdx, tcIdx + testCasesCount);
            }
        }