Everything that can be disposed of should be getting done automatically by the using:
using (var testEntities = new TestEntities(connectionString)) { Assert.AreEqual(1, testEntities.Users.Count(), "Must be one user"); var firstOrDefault = testEntities.Users.FirstOrDefault(); if (firstOrDefault != null) { Assert.AreEqual("1234", firstOrDefault.Id, "ID mismatch"); } } but I still cannot delete the file after the using. -- Michael Russell MTI Film, LLC michael.russ...@mtifilm.com http://www.mtifilm.com/ Providence, RI 02906 USA +1 (401) 831-1315 On Wed, Jan 9, 2013 at 12:06 PM, Joe Mistachkin <sql...@mistachkin.com>wrote: > > Michael Russell wrote: > > > > One further follow-up. I tested all the other versions in between. The > > break happened between 1.0.81.0 and 1.0.82.0 > > > > The switch to using sqlite3_close_v2 happened in that time frame; however, > the root cause of the issue you are seeing is that one or more > System.Data.SQLite objects have not been disposed and it's holding the > database connection and it's associated file(s) open. > > -- > Joe Mistachkin > > _______________________________________________ > sqlite-users mailing list > sqlite-users@sqlite.org > http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users > _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users