title: Entity Framework DbContext Connection string in app.config/web.config not being seen
body: <p>So, I have followed this instruction from ADO.NET team blog to try to make a small test project.
  I have double-checked everything. It doesn't seem to work and keeps saying connection string is missing.</p>
  
  <p><a href="http://blogs.msdn.com/b/adonet/archive/2011/03/15/ef-4-1-model-amp-database-first-walkthrough.aspx" rel="nofollow">http://blogs.msdn.com/b/adonet/archive/2011/03/15/ef-4-1-model-amp-database-first-walkthrough.aspx</a></p>
  
  <p>Step. 1
  Build this UserModels.dll. In the dll, App.Config file, edmx generated this connection string: (hit the 'test' button when making it, and it connects successfully, and generated the edmx diagram of all the tables from 'UserDatabase')</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;
  &lt;configuration&gt;
    &lt;connectionStrings&gt;
      &lt;add name="UserModelsContainer" connectionString="metadata=res://*/UserModels.csdl|res://*/UserModels.ssdl|res://*/UserModels.msl;provider=System.Data.SqlClient;provider connection string=&amp;quot;data source=MyDesktop\SQL2008;initial catalog=UserDatabase;integrated security=True;multipleactiveresultsets=True;App=EntityFramework&amp;quot;" providerName="System.Data.EntityClient" /&gt;
    &lt;/connectionStrings&gt;
  &lt;/configuration&gt;
  </code></pre>
  
  <p>Step 2. 
  Then I made a test project:</p>
  
  <pre><code>class UnitTetst1 ....
  TestMethod1()....
  using (var db = new UserModelsContainer()) {
    int i = db.Users.Count(); // &lt;---expecting '0' for a new db, but I get an exception
  }
  </code></pre>
  
  <p>---------PROBLEM HERE -----------------</p>
  
  <p>Step 3. Run the test. Then I get an error InvalidOperationException like this:</p>
  
  <pre><code>"No connection string named 'UserModelsContainer' could be found in the application config file."
  </code></pre>
  
  <p>Seems like DbContext doesn't know where to pick up the connectionStrings from App.Config??</p>
  
  <p>Please help~~</p>