Nunit Test Runner: current directory?

What directory does the nunit test runner run things from, and is there some
way to configure that?

I ask because, for numerous reasons, we have a post-build step that copies
our DLLs into a common DLL, and they really need to run from there. That's
where the .config files are, and other required referenced assemblies, etc
(for things that are dynamically linked rather than explicitly referenced).

Is there some way to tell the unit test runner "run from THIS directory", so
that I can get it to actually work for our project?


2 comments
Comment actions Permalink

In build 202, this is the directory where the tested DLL is located.
NUnit itself does the same

--
Eugene Pasynkov
Developer
JetBrains, Inc
http://www.jetbrains.com
"Develop with pleasure!"
"Paul Bradshaw" <pbradshaw@advsol.com> wrote in message
news:dc6gip$5qt$1@is.intellij.net...

What directory does the nunit test runner run things from, and is there
some way to configure that?

>

I ask because, for numerous reasons, we have a post-build step that copies
our DLLs into a common DLL, and they really need to run from there.
That's where the .config files are, and other required referenced
assemblies, etc (for things that are dynamically linked rather than
explicitly referenced).

>

Is there some way to tell the unit test runner "run from THIS directory",
so that I can get it to actually work for our project?



0
Comment actions Permalink

The problem is, I need to configure the directory it runs from. I can do
this in Visual Studio because I set a start up project, specify the program
to run (the nunit gui), and specify the directories, command lines, etc.
I'll need this same flexibility to specify the directory to run in if the
nunit test runner is to be of any use to me or anyone in my company.

Essentially, the DLL is built to the normal Debug directory, and a
post-build step copies it to a \bin directory with all the other DLLs for
our very large project. These DLLs must be co-located because we
dynamically load them (we don't use 70 hard-coded references, we dynamically
load any of the 70 DLLs that is needed at run-time). So the nunit test
runner must run the DLL from the \bin directory (which is also where the
.config files are that have crucial config information, log ins, database
connection info, etc). Unless I can point the nunit test runner to this
\bin directory and run the dll from there, it's completely useless.


"Eugene Pasynkov (JetBrains)" <Eugene.Pasynkov@jetbrains.com> wrote in
message news:dc7cs2$kfd$1@is.intellij.net...

In build 202, this is the directory where the tested DLL is located.
NUnit itself does the same

>

--
Eugene Pasynkov
Developer
JetBrains, Inc
http://www.jetbrains.com
"Develop with pleasure!"
"Paul Bradshaw" <pbradshaw@advsol.com> wrote in message
news:dc6gip$5qt$1@is.intellij.net...

>> What directory does the nunit test runner run things from, and is there
>> some way to configure that?
>>
>> I ask because, for numerous reasons, we have a post-build step that
>> copies our DLLs into a common DLL, and they really need to run from
>> there. That's where the .config files are, and other required referenced
>> assemblies, etc (for things that are dynamically linked rather than
>> explicitly referenced).
>>
>> Is there some way to tell the unit test runner "run from THIS directory",
>> so that I can get it to actually work for our project?
>>
>




0

Please sign in to leave a comment.