.net - How to avoid duplicate settings when using 2 projects and 2 testing projects in Visual Studio? -


My following, now I have 2 projects: a consoles project and a library project they also have their own unit testing projects. When I use a method from the Library Project that runs a test for the console project and the library project requires the app.config setting, then this setting should be in the App.config of the console test project. What to do to read the settings from config, then I do not have to duplicate settings in many app config?

Updates I do not want to use the same app. Conflict for both projects. Now what I have to do, but do not want to do anymore, all the library apps in the console project settings. Copying config settings

If the Library Project is a Class Library, then it requires a reference to run inside. The VS will not read the app.config file for a class library, it only reads app.cconfig file from the execution context, which I can tell the settings should be in the console.apen.config because it is the reference to execution. If you are running unit tests and they are performance reference, they will also need their own app.config.


Comments