Relative paths in test code problem

Relative paths in test code problem

I know this is stupid, but I can't figure it out. In our solution, we specify the relative paths to a file one of our tests needs as -

../../../TestSuite/XMLTestFiles/Local.xml

Now, this works fine when running the testing out of VS with MSTest.exe. However, in NCover all of the tests fail. I assume NCover is executing MSTest in a different directory than VS. Does anyone know how I can go about fixing this? I can't move the file's location. Thanks!


RE: Relative paths in test code problem

you can use the //w argument to tell NCover where to search for relative-paths from.

http://docs.ncover.com/ref/3-0/ncover-console/command-line/program-settings#w