Compatibility of the Test Adapter with the Test Engine
NUnit3TestAdapter has an embedded
NUnit.Engine package. This means that you don't need to install the engine
separately, and you don't need to add a reference to the engine in your test project.
You should never add an extra reference to the
NUnit.Engine when using the adapter in a project, as that may cause
the adapter to malfunction.
The table below shows the embedded engine versions for the different adapter versions, extended from Charlie's blog post.
|Adapter version||Embedded engine version|
Using the console
If, for some unknown reason, you really badly want to use the NUnit.Console, and you really want to add it as a package reference instead of just installing it globally, you should use the exact same version as listed for the engine in the table above.
Note that most of what the console can do, can be done using the
dotnet test command with the appropriate runsettings
added, see Tips&Tricks.
If you try to add another engine version package, it may seem that the adapter and test are still working. That is just by luck, and it does so because the interfaces between the version you have added are the same as the embedded version. But if you try to use a feature that is not in the embedded version, it will fail.
Most likely you will see messages about "no tests found", or it may simply crash during test.
Version 4.4.1 use an engine version that is not released yet. This is because the engine has a bug that prevents it from working with the adapter. The bug is fixed in the engine, but the fix is not yet released. The adapter will be updated to use the released engine version as soon as it is released. You may try to use 3.15.2, but we can currently not confirm that it works.