I'm trying to access a file in my solution structure during the unit test. My unit test project has the binDebug
as the output directory. So I have written the code assuming that Path.GetFullPath(".")
in my unit test will give me this bin folder. But what it does is it gives me a temporary location as the path.
C:Users[username]AppDataLocalTempTestResults[username]_[machine_name] 2013-05-16 08_31_07Out
So obviously my unit test couldn't access the files in my solution. If anyone knows how to make unit test run in the bin folder of the unit test project please help.
See Question&Answers more detail:os