Welcome Guest! To enable all features please Login or Register.

Notification

Icon
Error

Netcore failed: An assembly specified in the application dependencies manifest was not found
lukesch
#1 Posted : Friday, September 18, 2020 10:41:40 PM(UTC)
Rank: Member

Groups: Registered
Joined: 5/10/2014(UTC)
Posts: 13

Thanks: 1 times
Was thanked: 1 time(s) in 1 post(s)
I was having many problems getting ncrunch to work on a netcoreapp3.1 unit test project. I was receiving the error:

Quote:
An error occurred while analysing this project after it was built: NCrunch encountered an unexpected error occurred while building an environment to analyse an assembly: nCrunch.TaskRunner.Ipc.IpcConnectionClosedException: The connection has been closed
at nCrunch.Core.ProcessManagement.ExternalProcessManager.(ProcessorArchitecture , ProcessLoadParameters )
at nCrunch.Core.ProcessManagement.ExternalProcessManager.LoadExternalProcess(ProcessLoadParameters parameters, GridClientId client)
at nCrunch.Core.TestManagement.TestRunnerProcess..()
at nCrunch.Common.PerformanceTracking.PerfTracker.TrackActivity(String name, Action activity)
at nCrunch.Core.TestManagement.TestRunnerProcess.(Nullable`1 , FilePath , GridClientId , CustomEnvironmentVariable[] )
at nCrunch.Core.TestManagement.TestRunnerProcess..()
at nCrunch.Common.PerformanceTracking.PerfTracker.TrackActivity(String name, Action activity)
at nCrunch.Core.Processing.AnalysisTaskLogic.DoProcessTaskAndReturnSuccessFlag()


I turned on
Log to Output Window: true
Log Verbosity: detailed

and discovered by looking in the processing queue for my busted tests that the commandline ncrunch was running. I ran the command myself and received this error

Quote:
(15:20:54.55) λ "C:\Program Files\dotnet\dotnet.exe" "C:\Users\lukesch.REDMOND\AppData\Local\NCrunch\2124\10\Git\Bothell\sources\test\Common\src\SecureStringUtilsTests\bin\x64\nCrunch.TaskRunner.DotNetCore.20.x64.dll" 2124 nCrunch_cf0f0bc823f44e83b0a77bbfd716caad 9881cff346ce497dbb11a527d90a60cd "c:\program files (x86)\microsoft visual studio\2019\enterprise\common7\ide\extensions\remco software\ncrunch for visual studio 2019\nCrunch.TestExecution.DotNetCore.dll" nCrunch.TestExecution.RemoteTaskRunner "C:\Users\lukesch.REDMOND\AppData\Local\NCrunch\2124\10\Git\Bothell\sources\test\Common\src\SecureStringUtilsTests\bin\x64" "False" "C:\Users\lukesch.REDMOND\AppData\Local\NCrunch\2124\10\Git\Bothell\sources\test\Common\src\SecureStringUtilsTests\bin\x64\Internal.Exchange.Build.Applications.Common.SecureStringUtilsTests.dll.config.ncrunchconfig"
Error:
An assembly specified in the application dependencies manifest (nCrunch.TaskRunner.DotNetCore.20.x64.deps.json) was not found:
package: 'FluentAssertions', version: '5.10.3'
path: 'lib/netcoreapp2.1/FluentAssertions.dll'


The only way I could figure out how to fix this was to turn on "Copy Referenced Assemblies to Workspace" for the test project. Is there a better way? These tests work fine running directly out of visual studio.
Remco
#2 Posted : Saturday, September 19, 2020 12:16:49 AM(UTC)
Rank: NCrunch Developer

Groups: Administrators
Joined: 4/16/2011(UTC)
Posts: 7,144

Thanks: 959 times
Was thanked: 1290 time(s) in 1196 post(s)
Hi, thanks for sharing this problem.

Normally, this shouldn't happen. When the assembly is specified in the .deps.json file, the runtime should be able to find it without it needing to be copied to the runtime directory. Somewhere in the toolset there is something unexpected going on.

If you create a sample project referencing FluentAssertions, do you get the same result? Are you able to build a small sample that can produce this problem that you might be able to share with me?
Users browsing this topic
Guest
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.

YAF | YAF © 2003-2011, Yet Another Forum.NET
This page was generated in 0.039 seconds.
Trial NCrunch
Take NCrunch for a spin
Do your fingers a favour and supercharge your testing workflow
Free Download