Forum Discussion

MW_Didata's avatar
MW_Didata
Regular Contributor
11 months ago
Solved

Send log reports to co-workers

Our tests are run every night project by project through Sessioncreate with batchscripting. we have an email message service which logs which projects fail but not the details where or why it failed ...
  • rraghvani's avatar
    11 months ago

    The command that I use is,

    $tc_timestamp = (Get-Date).ToString('yyyyMMdd_HHmmss')
    $summary_report = "C:\Sandbox\Log\TC_Automation_$tc_timestamp\SummaryReport.xml"
    & 'C:\Program Files (x86)\SmartBear\TestExecute 15\x64\Bin\SessionCreator.exe' RunTest /UserName:Tester1 /password:'Tester1' /UseActiveSession /ScreenResolution:"1920*1080" /ProjectPath:"C:\Sandbox\TestComplete\ALS\ALS.pjs" /ExportLog:"C:\Sandbox\Log\TC_Automation_$tc_timestamp\index.html" /ExportSummary:"$summary_report" | Out-Null

    The log filenames are based on the timestamp, so I keep a record of execution runs/results.

     

    /ExportSummary produces an XML file, which I parse via PowerShell to produce a HMTL report. /ExportLog is the actual log produced by TC. See Command-Line Syntax