Matt
Matt

Reputation: 1043

How to get a results file from Nunit Test Adapter ran in Visual Studio with Test Explorer

I have been running my tests with Specflow+ through Test Explorer in Visual Studio and a nice .html report is automatically generated at the end by the Specflow+ Runner.

I have switched to Nunit Test Runner (still running through Test Explorer).

However, at the end I can't see any results files at all xml or html?

How do I get it to generate these? Or am I looking in the wrong place?

I tried adding a .runsettings file in the root of the project containing the following code but still no results were written:

<?xml version="1.0" encoding="utf-8"?>
<RunSettings>
    <NUnit>
        <TestOutputXml>TestResults</TestOutputXml>
    </NUnit>
</RunSettings>

Upvotes: 2

Views: 1394

Answers (1)

Charlie
Charlie

Reputation: 13726

It's necessary to tell TestExplorer to use the .runSettings file. See https://learn.microsoft.com/en-us/visualstudio/test/configure-unit-tests-by-using-a-dot-runsettings-file?view=vs-2019

Upvotes: 3

Related Questions