Description
hello. i'm very excited your work.
but sadly not works for me...
-
open unity 2017.1.2f1 / NCrunch 3.11.0.9 / VS2017
-
add edit mode test. test runner > pass
-
install adapter from asset store
-
close unity
-
open unity. open testcode with vs (by unity editor)
-
NCrunch throw casting error.
-
solutions reference not changed. (still C:/Program Files/Unity/Editor/Data/UnityExtensions/Unity/TestRunner/net35/unity-custom/nunit.framework.dll)
-
i add small debug line
ProjectFilesGenerator.ProjectFileGeneration += (string name, string content) =>
{
Debug.Log("change done!");
return content.Replace(NUnitUnityReference, NUnitOfficialReference);
};
9. close unity. open unity.
10. i can see "change done!" twice.
11. open testcode.
12. still same. not works (like .6)
NCrunch error line
An error occurred while analysing this project after it was built: System.Reflection.TargetInvocationException: 호출 대상이 예외를 Throw했습니다. ---> System.InvalidCastException: 'nCrunch.Module.NUnit3.Integration.NUnit3CallbackProxy' 형식 개체를 'System.Web.UI.ICallbackEventHandler' 형식으로 캐스팅할 수 없습니다.
위치: NUnit.Framework.Api.FrameworkController.LoadTestsAction..ctor(FrameworkController controller, Object handler)
--- 내부 예외 스택 추적의 끝 ---
위치: System.RuntimeMethodHandle._InvokeConstructor(Object[] args, SignatureStruct& signature, IntPtr declaringType)
위치: System.RuntimeMethodHandle.InvokeConstructor(Object[] args, SignatureStruct signature, RuntimeTypeHandle declaringType)
위치: System.Reflection.RuntimeConstructorInfo.Invoke(BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
위치: System.RuntimeType.CreateInstanceImpl(BindingFlags bindingAttr, Binder binder, Object[] args, CultureInfo culture, Object[] activationAttributes)
위치: System.Activator.CreateInstance(Type type, BindingFlags bindingAttr, Binder binder, Object[] args, CultureInfo culture, Object[] activationAttributes)
위치: nCrunch.Module.NUnit3.Integration.FrameworkController.LoadTests(INUnit3CallbackHandler handler)
위치: nCrunch.Module.NUnit3.Integration.NUnit3FrameworkInteractor.b__7_0()
위치: nCrunch.Common.PerformanceTracking.PerfTracker.TrackActivity(String name, Action activity)
위치: nCrunch.Common.PerformanceTracking.PerfTracker.TryTrackActivity(String name, Action activity)
위치: nCrunch.Module.NUnit3.Integration.NUnit3FrameworkInteractor.prepareFramework(DynamicProxy[] dynamicProxies)
위치: nCrunch.Module.NUnit3.Integration.NUnit3FrameworkInteractor..ctor(ReflectedAssembly assembly, IList1 referencedAssemblyFilePaths, ComponentUniqueName testComponentUniqueName, DynamicProxy[] dynamicProxies) 위치: nCrunch.Module.NUnit3.Integration.NUnit3FrameworkRuntimeEnvironment.FindFrameworkTestsInAssembly(ReflectedAssembly assembly, FilePath assemblyFilePath, IList
1 referencedAssemblyFilePaths, ComponentUniqueName testComponentUniqueName, PlatformType platformType, DynamicProxy[] dynamicProxies)
위치: nCrunch.TestExecution.TestFinder.�.�()
위치: nCrunch.Common.PerformanceTracking.PerfTracker.TrackActivity(String name, Action activity)
위치: nCrunch.TestExecution.TestFinder.�.�()
위치: nCrunch.Common.PerformanceTracking.PerfTracker.TrackActivity(String name, Action activity)
위치: nCrunch.TestExecution.TestFinder.FindTestsForFrameworks(ReflectedAssembly assembly, FilePath assemblyFilePath, IList`1 referencedAssemblyFilePaths, DescribedTestFrameworkDiscoverer[] describedDiscoverers, ComponentUniqueName testComponentUniqueName, PlatformType platformType, DynamicProxy[] dynamicProxies)
위치: nCrunch.TestExecution.RemoteTaskRunner.AnalyseAssembly(DescribedTestFrameworkDiscoverer[] applicableFrameworks, ComponentUniqueName testComponentUniqueName, PerfTracker perfTracker)
plus : when i change Nunit dll from
Files\Unity\Editor\Data\UnityExtensions\Unity\TestRunner\net35\unity-custom\nunit.framework.dll
to your asset's Nunit dll,
'NCrunch works fine, but Unity TestRunner fail'
in this case, can't test monobehaviors. not helpful :(