Created
October 16, 2018 00:31
-
-
Save dcomartin/6556a56b28632292dba6d32367ed2cd7 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var options = new DbContextOptionsBuilder<MyDbContext>() | |
.UseInMemoryDatabase(databaseName: "Test") | |
// Don't raise the error warning us that the in memory db doesn't support transactions | |
.ConfigureWarnings(w => w.Ignore(InMemoryEventId.TransactionIgnoredWarning)) | |
.Options; | |
var dbContext = new MyDbContext(options); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment