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

Download this file

49 lines (49 with data), 5.8 kB

Gx_lЗ!0Еj№o╓С1▐ЙЭk5┘System.StringL{f8a58466-d7f6-439f-bbb8-d4600e41d099}ImplementationL{3b83b776-fb25-43b8-99f2-3c507c9143fc}TextDocumentL{f3878285-8e4f-490b-bb1b-9acbb7eb04db}TextLinesL{a5de0b0b-1cb5-4913-ac21-9d70293ec00d}	Id
longTagText
8(* Run TcUnit test suites *)BIF NOT AllTestSuitesFinished THENp    IF GVL_CfUnit.NumberOfInitializedTestSuites = 0 THENL        AllTestSuitesFinished := TRUE;v    ELSIF GVL_CfUnit.NumberOfInitializedTestSuites > 0 THENШ        FOR Counter := 1 TO GVL_CfUnit.NumberOfInitializedTestSuites BY 1 DOв            IF GVL_CfUnit.TestSuiteAddresses[Counter]^.AreAllTestsFinished() THENЪ                NumberOfTestSuitesFinished := NumberOfTestSuitesFinished + 1;             ELSE┬                GVL_CfUnit.CurrentTestSuiteBeingCalled := GVL_CfUnit.TestSuiteAddresses[Counter];t                GVL_CfUnit.CurrentTestSuiteBeingCalled^();$            END_IF        END_FOR╩        (* Check if some event triggered an abortion of running the tests, in that case abort it now.└           This can be accomplished by setting the result of the test suites run to finished. *)L        IF AbortRunningTestSuites THENж            NumberOfTestSuitesFinished := GVL_CfUnit.NumberOfInitializedTestSuites;		END_IFк        IF NumberOfTestSuitesFinished = GVL_CfUnit.NumberOfInitializedTestSuites THEN T            AllTestSuitesFinished := TRUE;!        END_IF"    END_IF#END_IF$%V(* Store test suite results continuously *)&TestResults();'R(* Log test suite results continuously *)(NTestResultLogger.LogTestSuiteResults();)B(* Run the buffered ADS logger *)*>//GVL_CfUnit.AdsMessageQueue();+@(* publish the jUnit Xml code *),FXmlPublisher.LogTestSuiteResults();-Interface.L{a9ed5b7e-75c5-4651-af16-d2c27e98cb94}/0METHOD RunTestSuiteTests0VAR10    Counter : UINT := 0;20    BusyPrinting : BOOL;3END_VAR4VAR_INST5▐    (* We need to hold a temporary state of the statistics (failed, successful, total number of test cases etc)6▐       as we don't consider the tests to be completely finished until all test suites have executed completely.7ш       The reason we want to do it this way is because a test suite can run over several cycles. Only once all tests8м       are finished (which might take many cycles), do we gather correct statistics *)9V    NumberOfTestSuitesFinished : UINT := 0;╨╨╨E#╨╨	
нД┌╨-
╨╨	
нY┌╨-╨╨	
нZ┌╨-╨╨	
н[┌╨-╨╨	
н\┌╨-╨╨	
н]┌╨-╨╨	
нЕ┌╨-╨╨	
нЖ┌╨-╨╨	
нЗ┌╨-╨╨	
нИ┌╨-╨╨	
нЙ┌╨-╨╨	
нf┌╨-╨╨	
нg┌╨-╨╨	
нh┌╨-╨╨	
нi┌╨-╨╨	
нj┌╨-╨╨	
нk┌╨-╨╨	
нl┌╨-╨╨	
нm┌╨-╨╨	
нn┌╨- ╨╨	
нo┌╨-!╨╨	
нp┌╨-"╨╨	
нM┌╨-#╨╨	
нN┌╨-$╨╨	
н┌╨-%╨╨	
нА┌╨-&╨╨	
нБ┌╨-$╨╨	
нВ┌╨-'╨╨	
нX┌╨-(╨╨	
нГ┌╨-$╨╨	
нU┌╨-)╨╨	
нq┌╨-*╨╨	
нt┌╨-$╨╨	
нs┌╨-+╨╨	
нr┌╨-,╨-.╨E╨╨	
нk┌╨-/╨╨	
нl┌╨-0╨╨	
нu┌╨-1╨╨	
нv┌╨-2╨╨	
нК┌╨-3╨╨	
нw┌╨-4╨╨	
нx┌╨-5╨╨	
нy┌╨-6╨╨	
нz┌╨-7╨╨	
н{┌╨-8╨╨	
нw┌╨-9╨╨	
н┌╨-3