Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

An exception occurred while invoking executor 'executor://nunit3testexecutor/' #1245

Open
thomhurst opened this issue Feb 27, 2025 · 1 comment

Comments

@thomhurst
Copy link

Upgrading NUnit3TestAdapter to v5, I get:

Error: An exception occurred while invoking executor 'executor://nunit3testexecutor/': Could not load file or assembly 'nunit.engine.api, Version=3.0.0.0, Culture=neutral, PublicKeyToken=2638cd05610744eb'. The system cannot find the file specified.

Stack trace:
   at NUnit.VisualStudio.TestAdapter.NUnit3TestExecutor.RunTests(IEnumerable`1 sources, IRunContext runContext, IFrameworkHandle frameworkHandle)
   at Microsoft.VisualStudio.TestPlatform.Common.ExtensionDecorators.SerialTestRunDecorator.RunTests(IEnumerable`1 sources, IRunContext runContext, IFrameworkHandle frameworkHandle) in /_/src/Microsoft.TestPlatform.Common/ExtensionDecorators/SerialTestRunDecorator.cs:line 57
   at Microsoft.VisualStudio.TestPlatform.CrossPlatEngine.Execution.RunTestsWithSources.InvokeExecutor(LazyExtension`2 executor, Tuple`2 executorUriExtensionTuple, RunContext runContext, IFrameworkHandle frameworkHandle) in /_/src/Microsoft.TestPlatform.CrossPlatEngine/Execution/RunTestsWithSources.cs:line 114
   at Microsoft.VisualStudio.TestPlatform.CrossPlatEngine.Execution.BaseRunTests.RunTestInternalWithExecutors(IEnumerable`1 executorUriExtensionMap, Int64 totalTests) in /_/src/Microsoft.TestPlatform.CrossPlatEngine/Execution/BaseRunTests.cs:line 466

NUnit version is 4.3.2

.NET 8

@mikkelbu
Copy link
Member

mikkelbu commented Mar 1, 2025

@thomhurst I'm moving this to the nunit3-vs-adapter repo. Can you provide some more information about your setup - e.g.

  • are you running testes from the commandline or via an IDE
  • I assume that you don't have any references to nunit.engine.api, but this comes from the NUnit3TestAdapter
  • Can you provide a minimal example

I'm unsure if it helps in this case, but it helps to remove cache data and old build output e.g. via git clean -xdf

@mikkelbu mikkelbu transferred this issue from nunit/nunit Mar 1, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants