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

Notification

Icon
Error

Having trouble with a Portable Class Library (PCL) - Load Failure
cskardon
#1 Posted : Thursday, November 5, 2015 2:14:30 PM(UTC)
Rank: Newbie

Groups: Registered
Joined: 11/27/2012(UTC)
Posts: 8
Location: United Kingdom

Was thanked: 1 time(s) in 1 post(s)
I have a PCL targeting .NET 4.6 and Windows 10 Universal Apps

Build wise - it's working fine, Resharper's XUnit is all running the tests well, but NCrunch is telling me there is a load failure, missing a `global.json` file.

AFAIK, I don't need a global.json file do I?

The exception is:



System.Exception: An exception was thrown in the remote environment: System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> nCrunch.Common.UserException: Unable to resolve the global.json file from 'D:\Projects\Test Applications\TestPortable'. This file is required to be in a parent directory of the project being built.
at nCrunch.Compiler.DnxIntegration.GlobalJson.(DirectoryPath )
at nCrunch.Compiler.DnxIntegration.GlobalJson..ctor(DirectoryPath projectJsonDirectory)
at nCrunch.Compiler.RemoteBuildRunner.AnalyseComponentBuild(FilePath projectFilePath, BuildXml buildXml, String useBuildConfiguration, String useBuildPlatform, DirectoryPath solutionDir, String solutionName, List`1 importExpressionsToEvaluate, ProcessorArchitecture buildProcessProcessorArchitecture, DirectoryPath workspaceBasePath)
--- End of inner exception stack trace ---
at System.RuntimeMethodHandle.InvokeMethod(Object target, Object[] arguments, Signature sig, Boolean constructor)
at System.Reflection.RuntimeMethodInfo.UnsafeInvokeInternal(Object obj, Object[] parameters, Object[] arguments)
at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
at nCrunch.TaskRunner.Ipc.IpcMessageProcessor.(CallMethodMessage )
at nCrunch.TaskRunner.Ipc.IpcMessageProcessor.ProcessMessageReturningResult(Byte[] data)
at nCrunch.TaskRunner.Ipc.RemoteInstance.[T](Byte[] )
at nCrunch.TaskRunner.Ipc.RemoteInstance.Invoke(IMessage msg)
at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgData, Int32 type)
at nCrunch.Compiler.IRemoteBuildRunner.AnalyseComponentBuild(FilePath projectFilePath, BuildXml buildXml, String useBuildConfiguration, String useBuildPlatform, DirectoryPath solutionDir, String solutionName, List`1 importExpressionsToEvaluate, ProcessorArchitecture buildProcessProcessorArchitecture, DirectoryPath workspaceBasePath)
at nCrunch.Core.BuildManagement.BuildProcessLauncher..(IRemoteBuildRunner )
at nCrunch.Core.BuildManagement.BuildProcessLauncher.(Action`1 , ProcessorArchitecture , GridClientId , IBuildableProject , IList`1 )
at nCrunch.Core.BuildManagement.BuildProcessLauncher.AnalyseComponentBuildInExternalProcess(FilePath projectFilePath, BuildXml buildXml, String useBuildConfiguration, String useBuildPlatform, DirectoryPath solutionDir, String solutionName, List`1 importExpressionsToEvaluate, ProcessorArchitecture processorArchitecture, VisualStudioVersion vsVersion, IList`1 customEnvironmentVariables)
at nCrunch.Client.ComponentLoader.SnapshotComponentFactory.(ProcessorArchitecture )
at nCrunch.Client.ComponentLoader.SnapshotComponentFactory.CreateSnapshotComponentFromXml(FilePath projectFilePath, BuildXml projectXml, FilePath solutionFilePath, String[] additionalFilesToIncludeAtSolutionLevel, Boolean isLoadedFromFile, ISnapshotConfig snapshotConfig, VisualStudioVersion vsVersion)
Remco
#2 Posted : Thursday, November 5, 2015 10:30:17 PM(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 issue.

It looks like NCrunch is unable to properly identify this project type, and it thinks it's compiling a DNX project.

Do you know which VS project template was used to create this project? Or can you share any sample code using the contact form?
Remco
#3 Posted : Thursday, November 5, 2015 11:07:38 PM(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)
I've managed to reproduce this issue using a Universal Class Library project template. It looks like this project type has the same structure as a DNX project, with a few differences. Sorry, I won't be able to provide you with a solution to this problem until DNX support is added to NCrunch. Universal Apps aren't actually supported by NCrunch right now, so at best this may end up being a project that builds but cannot run tests.
cskardon
#4 Posted : Friday, November 6, 2015 7:59:26 AM(UTC)
Rank: Newbie

Groups: Registered
Joined: 11/27/2012(UTC)
Posts: 8
Location: United Kingdom

Was thanked: 1 time(s) in 1 post(s)
OK, well, good to know it's not an error on my front!
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.038 seconds.
Trial NCrunch
Take NCrunch for a spin
Do your fingers a favour and supercharge your testing workflow
Free Download