TeamCity Build Agent and Ranorex Assembly Dependencies

Ask general questions here.
benny28
Posts: 34
Joined: Thu May 31, 2012 4:48 pm
Location: London
Contact:

TeamCity Build Agent and Ranorex Assembly Dependencies

Post by benny28 » Fri Jun 29, 2012 3:55 pm

Hi :)

I'm trying to configure TeamCity to run my automation suite. I have my Ranorex premium licence installed on a VM, this is the same VM that I (currenly manually using Nunit UI) use as my test agent.

After working through various errors I am left with this:

System.IO.FileNotFoundException: Could not load file or assembly 'Ranorex.Core, Version=3.3.0.17843, Culture=neutral, PublicKeyToken=b798506b574ebc9a' or one of its dependencies. The system cannot find the file specified.
File name: 'Ranorex.Core, Version=3.3.0.17843, Culture=neutral, PublicKeyToken=b798506b574ebc9a'


This says to me that the TeamCity Build Agent cannot find the Ranorex assembly dependencies, as the Build Agent is a separate machine and therefore does not have Ranorex installed. Does my 1 user licence type allow for the dependencies to be installed in the Build Agent? Is there a workaround for this?

Or is this error relating to something different?

Code: Select all

Build errors (full output)
 [15:20:17]Step 2/2: NUnit (17s)
[15:20:34][Step 2/2] 
NUnit error running tests in 'F:\BuildAgent\BuildAgentB\work\d2f85edc0b09fd2e\PosClient\bin\Debug\PosClient.dll' assebmly
Loading assembly is compiled for v4.0.30319, MSIL
NUnit runner runtime is v4.0.30319, x64
System.IO.FileNotFoundException: Could not load file or assembly 'Ranorex.Core, Version=3.3.0.17843, Culture=neutral, PublicKeyToken=b798506b574ebc9a' or one of its dependencies. The system cannot find the file specified.
File name: 'Ranorex.Core, Version=3.3.0.17843, Culture=neutral, PublicKeyToken=b798506b574ebc9a'

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.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\c2314fd21f15dc97\src\NUnitLauncher\src\NUnit-2.6\NUnitRunner.cs:line 44
   at JetBrains.TeamCity.NUnitLauncher.AssemblyTest.LoadTestDomain() in c:\BuildAgent\work\c2314fd21f15dc97\src\NUnitLauncher\src\AssemblyTest.cs:line 76
   at JetBrains.TeamCity.NUnitLauncher.LoadTestDomainAction.Action(AssemblyTest test) in c:\BuildAgent\work\c2314fd21f15dc97\src\NUnitLauncher\src\LoadTestDomainAction.cs:line 17
   at JetBrains.TeamCity.NUnitLauncher.TryOneAssemblyTest.Action() in c:\BuildAgent\work\c2314fd21f15dc97\src\NUnitLauncher\src\TryOneAssemblyTest.cs:line 18
   at JetBrains.TeamCity.NUnitLauncher.TryOneAssembly.Do() in c:\BuildAgent\work\c2314fd21f15dc97\src\NUnitLauncher\src\TryOneAssembly.cs:line 31

User avatar
Support Team
Site Admin
Site Admin
Posts: 11709
Joined: Fri Jul 07, 2006 4:30 pm
Location: Graz, Austria

Re: TeamCity Build Agent and Ranorex Assembly Dependencies

Post by Support Team » Mon Jul 02, 2012 11:40 am

Hi,

You can't create Ranorex tests on a machine where Ranorex is not installed respectively no Ranorex license is installed.
Is your license a floating license or a node locked one?
If it is a node locked one you would need another license for your TeamCity Build Agent machine.
If you have additional questions about Pricing and Editions our sales team will be happy to assist you, [email protected].

Regards,
Markus
Ranorex Support Team
.
Image