nunit-console
nunit-console copied to clipboard
Add codebase path to nunit-agent config files
Since i would like to be able to package my whole directory along with the tests, the console runner and every other resource required and be able to execute the binaries without having to install assemblies in the GAC or manipulate the machine config i propose to add a codepath to the agents config files.
In this case i copied everything from all the packages tools directories into a testing folder where the nunit.framework.dll is along my test assemblies.
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly>
<assemblyIdentity name="nunit.framework" publicKeyToken="2638cd05610744eb" culture="neutral"/>
<codeBase version="3.13.1.0" href="../../../../../nunit.framework.dll"/>
</dependentAssembly>
</assemblyBinding>
Hi @DialLuesebrink,
This wouldn't be possible as you've written it - the console needs to run against every version of the framework, rather than being locked down specifically to v3.13.1. I'm not sure I fully understand the problem you're facing though - could you clarify what you're trying to do here? I don't understand why you can't package everything in a single directory anyway - that's what we do for the nunit-console.zip.
The version can be empty for assemblies that do not have a strong name. codebase-element
For assemblies without a strong name, version is ignored and the loader uses the first appearance of
inside <dependentAssembly>.
What i would like is to not copy anything after installing the packages. This way the agent is able to resolve the path to the assembly itself. At best i would be able to pass an argument to the console runner that passes this parameter to the agent when it is started where is should resolve assemblies. That way i do not have to modify anything.
For the other scenario i copy every package folder of all the installed NUnit package to my bin folder in a testing subdirectory.