nunit3-console "--showcopy" option becomes broken with SpecFlow 3.4.3

24 views
Skip to first unread message

Wenning Qiu

unread,
Aug 27, 2020, 5:20:48 PM8/27/20
to SpecFlow
Our smoke test job started failing with the error below after upgrading SpecFlow to 3.4.3 from 2.3.2. The error disappeared after removing "--shadowcopy" option.

D:\work\Modules\Framework\trunk>lib\debug\nunit3-console.exe --workers=1 --shadowcopy /framework:net-4.5 /config:Debug /work:Reports --where "cat != SlowTests && cat != SpecFlow" /result:TestResult-x64.xml;format=nunit2 Bin\Debug\net48\CSG.Framework.Test.dll
NUnit Console Runner 3.11.1 (.NET 2.0)
Copyright (c) 2020 Charlie Poole, Rob Prouse
Thursday, August 27, 2020 2:45:30 PM

Runtime Environment
   OS Version: Microsoft Windows NT 6.2.9200.0
   Runtime: .NET Framework CLR v4.0.30319.42000

Test Files
    Bin\Debug\net48\CSG.Framework.Test.dll

Test Filters
    Where: cat != SlowTests && cat != SpecFlow


Errors, Failures and Warnings

1) SetUp Error : CSG_Framework_Test_NUnitAssemblyHooks
BoDi.ObjectContainerException : Interface cannot be resolved: TechTalk.SpecFlow.UnitTestProvider.IUnitTestRuntimeProvider('nunit')
   at BoDi.ObjectContainer.TypeRegistration.Resolve(ObjectContainer container, RegistrationKey keyToResolve, ResolutionList resolutionPath)
   at BoDi.ObjectContainer.ResolveObject(RegistrationKey keyToResolve, ResolutionList resolutionPath)
   at BoDi.ObjectContainer.Resolve(Type typeToResolve, ResolutionList resolutionPath, String name)
   at BoDi.ObjectContainer.Resolve[T](String name)
   at TechTalk.SpecFlow.Infrastructure.ContainerBuilder.CreateGlobalContainer(Assembly testAssembly, IRuntimeConfigurationProvider configurationProvider)
   at TechTalk.SpecFlow.TestRunnerManager.CreateTestRunnerManager(Assembly testAssembly, IContainerBuilder containerBuilder)
   at TechTalk.SpecFlow.TestRunnerManager.GetTestRunnerManager(Assembly testAssembly, IContainerBuilder containerBuilder, Boolean createIfMissing)
   at TechTalk.SpecFlow.TestRunnerManager.OnTestRunStart(Assembly testAssembly, IContainerBuilder containerBuilder)
   at CSG_Framework_Test_NUnitAssemblyHooks.AssemblyInitialize() in D:\work\Modules\Framework\trunk\Src\Library\Framework.Test\obj\Debug\net48\NUnit.AssemblyHooks.cs:line 17

Run Settings
    RuntimeFramework: net-4.5
    DisposeRunners: True
    ShadowCopyFiles: True
    ActiveConfig: Debug
    WorkDirectory: Reports
    NumberOfTestWorkers: 1
    ImageRuntimeVersion: 4.0.30319
    ImageTargetFrameworkName: .NETFramework,Version=v4.8
    ImageRequiresX86: False
    ImageRequiresDefaultAppDomainAssemblyResolver: False

Test Run Summary
  Overall result: Failed
  Test Count: 1358, Passed: 0, Failed: 1358, Warnings: 0, Inconclusive: 0, Skipped: 0
    Failed Tests - Failures: 0, Errors: 1358, Invalid: 0
  Start time: 2020-08-27 19:45:30Z
    End time: 2020-08-27 19:45:36Z

Andreas Willich

unread,
Sep 8, 2020, 4:06:00 AM9/8/20
to SpecFlow
It looks like that the nunit3 console runner doesn't copy all assemblies in the shadow folder.
It is missing the runtime plugin for your unit test runner (TechTalk.SpecFlow.NUnit.SpecFlowPlugin.dll or similar).



--
You received this message because you are subscribed to the Google Groups "SpecFlow" group.
To unsubscribe from this group and stop receiving emails from it, send an email to specflow+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/specflow/ef28ed3d-42f8-487a-a502-ca029ade22cen%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages