NUnit Tests - runner does not find assemblies, works fine in Reshaper / Vs.NET?

TeamCity 6, just installed.

I have a problem ni that I am adding a runner to run NUnit tests to an existing VS.NET proejct.

The result is good overall, but some tests are totally failing with a technical issue I simply can not get my mind wrapped around. The errors are:

[16:50:02]: DataMonitor.Shared.dll[16:50:03]: NUnit Error: System.IO.FileNotFoundException: Could not load file or assembly DataMonitor.Shared, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. The system cannot find the file specified.File name: DataMonitor.Shared, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null'Server stack trace: at System.Reflection.RuntimeAssembly.GetExportedTypes(RuntimeAssembly assembly, ObjectHandleOnStack retTypes)at System.Reflection.RuntimeAssembly.GetExportedTypes()at NUnit.Core.CoreExtensions.InstallAdhocExtensions(Assembly assembly)at NUnit.Core.Builders.TestAssemblyBuilder.Load(String path)at NUnit.Core.Builders.TestAssemblyBuilder.Build(String assemblyName, Boolean autoSuites)at NUnit.Core.Builders.TestAssemblyBuilder.Build(String assemblyName, String testName, Boolean autoSuites)at NUnit.Core.TestSuiteBuilder.Build(TestPackage package)at NUnit.Core.SimpleTestRunner.Load(TestPackage package)at NUnit.Core.ProxyTestRunner.Load(TestPackage package)at NUnit.Core.ProxyTestRunner.Load(TestPackage package)at NUnit.Core.RemoteTestRunner.Load(TestPackage package)at System.Runtime.Remoting.Messaging.StackBuilderSink._PrivateProcessMessage(IntPtr md, Object[] args, Object server, Int32 methodPtr, Boolean fExecuteInContext, Object[]& outArgs)at System.Runtime.Remoting.Messaging.StackBuilderSink.PrivateProcessMessage(RuntimeMethodHandle md, Object[] args, Object server, Int32 methodPtr, Boolean fExecuteInContext, Object[]& outArgs)at System.Runtime.Remoting.Messaging.StackBuilderSink.SyncProcessMessage(IMessage msg, Int32 methodPtr, Boolean fExecuteInContext)Exception rethrown at [0]: at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg, IMessage retMsg)at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgData, Int32 type)at NUnit.Core.TestRunner.Load(TestPackage package)at JetBrains.TeamCity.NUnitLauncher.NUnitRunner.LoadTest(String testAssembly, String testName, TestRunner runner) in c:\BuildAgent\work\6223f0c8b1d45aaa\src\NUnitLauncher\src\NUnit-2.5\NUnitRunner.cs:line 42at JetBrains.TeamCity.NUnitLauncher.AssemblyTest.LoadTestDomain() in c:\BuildAgent\work\6223f0c8b1d45aaa\src\NUnitLauncher\src\AssemblyTest.cs:line 73at JetBrains.TeamCity.NUnitLauncher.LoadTestDomainAction.Action(AssemblyTest test) in c:\BuildAgent\work\6223f0c8b1d45aaa\src\NUnitLauncher\src\LoadTestDomainAction.cs:line 14at JetBrains.TeamCity.NUnitLauncher.TryOneAssemblyTest.Action() in c:\BuildAgent\work\6223f0c8b1d45aaa\src\NUnitLauncher\src\TryOneAssemblyTest.cs:line 18at JetBrains.TeamCity.NUnitLauncher.TryOneAssembly.Do() in c:\BuildAgent\work\6223f0c8b1d45aaa\src\NUnitLauncher\src\TryOneAssembly.cs:line 31WRN: Assembly binding logging is turned OFF.To enable assembly bind failure logging, set the registry value [HKLM\Software\Microsoft\Fusion!EnableLog] (DWORD) to 1.Note: There is some performance penalty associated with assembly bind failure logging.To turn this feature off, remove the registry value [HKLM\Software\Microsoft\Fusion!EnableLog].[16:50:03]: ##teamcity[buildStatus text='NUnit runner crashed on D:\TeamCity\buildAgent.1\work\Glori 2010 Trunk\vs\Rwe.Glori\Rwe.Glori.DataMonitor.Messages\obj\Release\Rwe.Glori.DataMonitor.Business.dll {build.status.text}' status='ERROR']

The main issue is that when I am looking into the corresponding folder the assembly IS THERE. We dont use strong signing. TeaCity handles the complete build.... I am at a loss where the issue can be.

* Test execution works perfectly fine from within Visual Studio with Resharper.

* The standard runner contains basically two steps relevant here. First, a Visual Studio runner that runs the one .sln file. Second, the Nunit runner that executes the NUnit tests, which is blowing

Anyone an idea?


1 comment

I'm having a similar (the same?) problem having just upgraded to TeamCity 6 from 5.

It seems that previously this picked up the correct path for a dll:

Fri.Xhl.Scraping.Tests.Integration\bin\$(Configuration)\Fri.Xhl.Scraping.Tests.Integration.dll

But now when the TeamCity runnner is running the tests the dll is only picked up when I explicitly specify the build configuration:

Fri.Xhl.Scraping.Tests.Integration\bin\Trunk\Fri.Xhl.Scraping.Tests.Integration.dll

I haven't finished investigating yet but possibly build config is no longer being correctly translated?

0

Please sign in to leave a comment.