How do I get real-time logging for VSTest in Teamcity?

We recently upgraded our team city install to TeamCity 9 in order to get the realtime test logging.
It looks like everything is configured correctly and when we run our tests on team city, it detects that the custom logger is installed and uses it for logging.
For example, here's a few lines from the test output:

[10:08:03][Step 6/6] VSTest reporting tests in real-time
[10:08:03][Step 6/6] VSTest executable: C:\Program Files (x86)\Microsoft Visual Studio 12.0\Common7\IDE\CommonExtensions\Microsoft\TestWindow\vstest.console.exe
[10:08:03][Step 6/6] Command line params: [[D:\BuildAgent\work\765599ed7b889db8\Tests.dll] [/Logger:TeamCity] [/Platform:x64] [/TestCaseFilter:TestCategory=CategoryA]]

However, we still do not get real-time logs coming from the system. It seems to wait until the test finishes running to display the logs. Does anyone know if there's any additonal work that needs to be done to enable this?
1 comment
Comment actions Permalink


1. Please check that VSTest plugin version and TeamCity version are compatible. If not try to install new plugin.
2. Have you chaked that logger was installed correctly using vstest.console.exe /ListLoggers in the console on agent machine?
3. Please attach screenshot of the build step settings and logs: to enable logging open the <agent home>/plugins/dotnetPlugin/bin folder. Make a backup copy of teamcity-log4net.xml. Replace teamcity-log4net.xml with the content of teamcity-log4net-debug.xml. Run the build. (After a debug log is created, it is recommended to roll back the change). Logs will be written to <Build_Agent_Root>/temp/buildTmp/TeamCity.NET. Please attach them and full build log.


Please sign in to leave a comment.