Skip to content

Instantly share code, notes, and snippets.

@jand187
Last active December 11, 2015 03:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jand187/4537031 to your computer and use it in GitHub Desktop.
Save jand187/4537031 to your computer and use it in GitHub Desktop.
Basic setup for Fluent NHibernate SQLite.InMemory
var sessionFactory = Fluently.Configure()
.Database(SQLiteConfiguration.Standard.InMemory())
.ShowSql())
.Mappings(m => m.FluentMappings.AddFromAssemblyOf<AdjecentType>())
.ExposeConfiguration(cfg =>
{
var schemaExport = new SchemaExport(cfg);
schemaExport.Execute(true, true, false);
})
.BuildSessionFactory();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment