[cmake-developers] CTest: Request review of topic "ctest-fix-run-serial"

Nils Gladitz nilsgladitz at gmail.com
Fri Oct 18 18:50:26 EDT 2013


Hello Bill,

I've updated the topic with (I think) improved sorting.
Tests are now prioritized by depth within the dependency graph and 
within each depth level they are further ordered by cost.
This gives better total test time for my test case and preserves 
correctness in relation to RUN_SERIAL:

    Test project /home/ngladitz/src/test/build
         Start 4: i_want_to_be_alone
    1/4 Test #4: i_want_to_be_alone ...............   Passed    3.03 sec
         Start 1: i_like_company
         Start 3: i_have_dependencies
         Start 2: i_like_company_too
    2/4 Test #1: i_like_company ...................   Passed    3.02 sec
    3/4 Test #2: i_like_company_too ...............   Passed    3.02 sec
    4/4 Test #3: i_have_dependencies ..............   Passed    3.02 sec

    100% tests passed, 0 tests failed out of 4

    Total Test time (real) =   6.06 sec


Nils

On 18.10.2013 00:03, Nils Gladitz wrote:
> StartTest() returns false without running the test if there are any 
> dependencies remaining.
>
> Nils
>
> On 17.10.2013 23:57, Bill Hoffman wrote:
>> On Thu, Oct 17, 2013 at 5:31 PM, Nils Gladitz <nilsgladitz at gmail.com 
>> <mailto:nilsgladitz at gmail.com>> wrote:
>>
>>     Hello Bill, thanks for looking into this!
>>
>>     All four tests in my example are still run (as you can see in the
>>     test output I provided).
>>     This includes the dependent test.
>>
>>     What I did change is that all tests (from an dependency or
>>     otherwise) are run from StartNextTests() which ensures that
>>     serial tests run alone rather than from StartTest() which did not
>>     seem to account for this.
>>
>> I am not saying it won't run all of the tests.  I am saying there is 
>> a danger it will ignore the depends with your change and run a depend 
>> before the test that depends on it.  I don't see it using the depends 
>> in the sort.  Maybe a better fix would be to make sure the sort takes 
>> the depends into consideration.
>>
>> Or, just change the depend starting in StartTest to make sure it does 
>> not start a serial test with another test running.
>>
>> -Bill
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/cmake-developers/attachments/20131019/995fc01d/attachment.html>


More information about the cmake-developers mailing list