1

I have a question about how to add an addtional search path to NUnit testing. Although I know it's not best practice, I need it for some reason.

Let me description the directory structure first:

RootFolder
    unit-test.dll
    folder1
        a.dll
        folder1-1
            b.dll
    folder2
        c.dll

I have put my unit test dll in RootFolder, and under it there are many folders and also sub-folders. in each folder/sub folder there are some dlls which is referenced by my test dll.
now when i run my test dll with NUnit, i want the test dll to load the reference dll in sub-folder when needed.
i know it will work if i put all the reference dll in the root folder(same folder as test dll) but i don't want to break my directory structure.

dirn
  • 19,454
  • 5
  • 69
  • 74
Jian
  • 11
  • 1
  • Maybe this will be helpful. https://stackoverflow.com/questions/1892492/set-custom-path-to-referenced-dlls – Kote Jan 27 '16 at 16:59
  • Before anyone can really help you, you will need to indicate what version of NUnit you are using and how you run the tests. In particular NUnit v2 and v3 have different command-line options. – Charlie Jan 30 '16 at 01:15
  • @Charlie - neither nuint 2 nor 3 have any command line options to help with this (as far as my search, which led me here, indicates so far). So specc'ing the exact NUnit version, while nice, won't help much here. – Martin Ba Jun 19 '18 at 06:44

0 Answers0