I am using NUnit 3 with Visual Studio 2017. I am trying to store both TRX and XML test results into the same output folder. The problem I am having is that the .runsettings <ResultsDirectory> path is relative to the Solution folder, whereas the <TestOutputXml> path is relative to the WorkingDirectory, which is not the same as the Solution directory. Thus, if I try to store the result output into a relative path using ".Results" for both .runsettings entries, I get two different Results folders - one in Bin, and the other in the Solution dir. I want one Results folder for both the TRX and XML output files to be in the same location (preferably relative to the Solution folder). How do I do this using .runsettings?
<?xml version="1.0" encoding="utf-8"?>
<RunSettings>
<RunConfiguration>
<!-- Path relative to VS solution directory -->
<ResultsDirectory>.TestResults</ResultsDirectory>
</RunConfiguration>
<LoggerRunSettings>
<Loggers>
<Logger friendlyName="trx" enabled="True">
<Configuration>
<LogFileName>TestResults.trx</LogFileName>
</Configuration>
</Logger>
</Loggers>
</LoggerRunSettings>
<NUnit>
<!-- Path relative to NUnit working directory -->
<TestOutputXml>.TestResults</TestOutputXml>
</NUnit>
</RunSettings>
文章源自玩技e族-https://www.playezu.com/181624.html文章源自玩技e族-https://www.playezu.com/181624.html