[r322]: / trunk / Library / POUs / FB_CfUnitRunner / RunTestSuiteTests / svnobj  Maximize  Restore  History

Download this file

27 lines (26 with data), 6.2 kB

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
(* Run TcUnit test suites *)
IF NOT AllTestSuitesFinished THEN
    IF GVL_CfUnit.NumberOfInitializedTestSuites = 0 THEN
        AllTestSuitesFinished := TRUE;
    ELSIF GVL_CfUnit.NumberOfInitializedTestSuites > 0 THEN
            IF GVL_CfUnit.TestSuiteAddresses[Counter]^.AreAllTestsFinished() THEN
                GVL_CfUnit.CurrentTestSuiteBeingCalled := GVL_TcUnit.TestSuiteAddresses[Counter];
                GVL_CfUnit.CurrentTestSuiteBeingCalled^();
            END_IF
        END_FOR
           This can be accomplished by setting the result of the test suites run to finished. *)
        IF AbortRunningTestSuites THEN
        IF NumberOfTestSuitesFinished_Temp = GVL_CfUnit.NumberOfInitializedTestSuites THEN
            AllTestSuitesFinished := TRUE;
        END_IF
    END_IF
END_IF$
(* Store test suite results continuously *)
TestResults();
(* Log test suite results continuously *)
TestResultLogger.LogTestSuiteResults();
(* Run the buffered ADS logger *)
//GVL_CfUnit.AdsMessageQueue();
(* publish the jUnit Xml code *)
    (* We need to hold a temporary state of the statistics (failed, successful, total number of test cases etc)
       The reason we want to do it this way is because a test suite can run over several cycles. Only once all tests