XUnit and Connection Strings

A real quick one but maybe a good one.

I was running the xUnit.gui.exe program to run units tests using xUnit… duh. Problem I ran into is that xUnit is not a part of the solution that the tests were. This caused issues when trying to run integration tests since the needed app.config wouldn’t be read by xUnit as the config file used when running an app is the config file from the topmost (Usually UI) project/application. So I made a wild guess that if I follow that logic, what little there may be, and add the connection strings to the xunit.gui.exe.config file as if it were an app.config/web.config, it should use the connection strings added… and turns out it did.

And there you have it… it being the solution and not a clown.