I have a test project in which I needs to load an XLSX file. For that, I added a file with copy-always so that it ends up in the build directory, but all of the following return a wrong path:
System.Reflection.Assembly.GetAssembly(typeof(testclass)).Location;
AppDomain.CurrentDomain.BaseDirectory
Directory.GetCurrentDirectory();
They all give me:
"C:\\Users\\username\\Documents\\visual-studio-projecten\\projectname\\TestResults\\username_ICT003 2012-06-20 12_07_06\\Out"
and I need
"C:\\Users\\username\\Documents\\visual-studio-projecten\\projectname\\TestProject\\bin\\Debug\\SupportFiles\\"
How do I accomplish that?