title: Do I need to dispose of a DbContext if it was created from an ObjectContext?
body: <p>I made some extension methods for counting related records and I don't want to explicitly pass the DbContext, so instead I get the ObjectContext and create a DbContext from it.</p>
  
  <p>Will the new DbContext get disposed when the original DbContext is dispose?</p>
  
  <pre><code>var original = new CustomDbContext("connectionString")
  var entity = original.Table.First()
  
  // in the extension method
  var objectContext = entity.GetObjectContext()
  var newDbContext = new CustomDbContext(objectContext, false)
  // dispose of newDbContext??
  
  // original caller
  original.Dispose()
  </code></pre>