Forum Discussion
I'm integrating the tests into TeamCity so I am using the command line to run the tests and exporting the log as an MHT file. However, in order to be able to see them within TeamCity they need to be in HTM/HTML format. But thank you for your help!
What is the command line utility are you running? There might be problem with the command line. You can write a sample piece of code to save the results as HTML in testcomplete and add it to "OnStop Test" event handler.
Please find attached snapshot using which I was able to open the index.html file.
- SmartUrsula8 years agoOccasional Contributor
"C:\Program Files (x86)\SmartBear\TestComplete 12\Bin\TestComplete.exe" "C:\BuildAgent\work\TestCompleteBuild\TestComplete\TestComplete\ProjectSuites\Core.pjs" /run /ExportLog:"%teamcity.build.checkoutDir%\Log.MHT" /ErrorLog:"%teamcity.build.checkoutDir%\Error.MHT" /exit /SilentMode
Where %teamcity.build.checkoutDir% is a specific directory I am using, would you mind sharing the process of how you got yours please?
- SmartUrsula8 years agoOccasional Contributor
Never mind thanks guys, I fixed it by running this powershell:
(Get-Content C:\BuildAgent\work\TestCompleteBuild\Log\_root.js) | Foreach-Object {$_ -replace "http:\/\/localhost\/", ""} | Set-Content C:\BuildAgent\work\TestCompleteBuild\Log\_root.js
Which deletes the directory heading for every script in the log, this makes it work on TeamCity.