nunit / nunit3-vs-adapter

NUnit 3.0 Visual Studio test adapter for use under VS 2012 or later
https://nunit.org
MIT License
202 stars 104 forks source link

How to use external test suite #1168

Closed WimLeflere closed 2 months ago

WimLeflere commented 2 months ago

Is it possible to use an external test suite with the VS adapter? How can that be configured?

Details

We are building library Foo (Foo.dll) which implements an interface (IFoo.dll). The interface team has a test suite for checking compatibility (IFoo.Tests.dll).

How can we run the tests using the Visual Studio adapter? E.g. execute IFoo.Tests on Foo?

Currently we use NUnit console runner, but that's harder to debug and select testcases.

OsirisTerje commented 2 months ago

Not quite sure what you mean here, but can guess a bit:

Assuming you have a cs project where these dll's are present, the Foo as a csproj by itself, since that is your code. The IFoo.Tests should be hosted by your own Foo.Tests, with nunit and nunit3testadapter as included nuget packages. Do that and it will run just fine dotnet test