There are 4 of us working on a solution right now. The solution consists of a central executable project (a Windows service) and a number of Class Library solutions. The Windows service has an app.config file, but the Copy to Output Directory setting for it is set to "Do not copy" for some reason, so we can ignore it for this discussion.
There are two different Class Library projects that have app.config files. In one of the projects, this gets copied into the bin\Debug folder as MyClassLibrary.dll.config, while the other DLL's bin\Debug folder has both a MyOtherClassLibrary.dll.config AND app.config in it. I'm not sure how that happened.
These are all of the app.config files in the solution.
There is an MSTest project in the solution. It has several classes with the [TestClass] attributes on them, each in their own .cs file. When I look at this project's bin\Debug folder, I find the MyClassLibrary.dll and App.config in it, but no MyOtherClassLibrary.dll. This is odd, but that's what I see.
When I go to run one of these tests, as you know, files get copied into a special test folder in the solution's TestResults folder. When I look in that folder, I find only a MyTestProject.dll.config file. And when I open this, its contents are those of the app.config file.
What's going on here? I thought Visual Studio merged all of the config files together? The lack of the settings from the MyClassLibrary.dll.config file (obviously) breaks the code that relies on it.
How do we fix this?
Tony
EDIT:
I just double checked the MyClassLibrary bin\Debug folder & that has both app.config & MyClassLibrary.dll.config, so I guess what I was seeing in MyOtherClassLibrary is normal. We just need a way to manage all of these settings.