I am trying to write integration tests with EF6. For this, I am using my own database initializer derived from DropCreateDatabaseAlways. In overridden Seed method, I create my entities. All is fine except that while saving context I get
----> System.Data.SqlClient.SqlException : The INSERT statement conflicted with the FOREIGN KEY constraint
It is irrelevant for my test to fully initialize my entities. Is there any way to programmatically disable constraints checks during integration tests with Entity Framework run?