Forum Discussion

CBleunven's avatar
CBleunven
Contributor
13 years ago

Getting information on the Runner version in the log

Hi to all,

I'm looking in the information saved in a log, and I don't find any mention about the version / type of the engine that run the test.



Is there a way to have this from a script to incorporate them in the log ?

I would like to know if the test was run through Test Complete or Test execute and the version of the engine that was used (9.0.XXX).



Thanks for help,



Christophe
  • AlexKaras's avatar
    AlexKaras
    Icon for Champion Level 3 rankChampion Level 3
    Hi Christophe,



    Something like below might inspire you:

    if (Sys.WaitProcess('TestComplete', 0).Exists) then

      strProcess := 'TestComplete'

    else

      strProcess := 'TestExecute';

    Log.Message(aqString.Format('Test is running using %s v.%i', strProcess, Sys.Process('Test*te').FileVersionInfo.MajorPart));
  • Hi Alex,

    thank you for your suggestion.

    It's a bit indirect but crafty and it works perfectly !



    Christophe