UpdateSchema extension method for FluentConfiguration
i4004 opened this issue · comments
Is your feature request related to a problem? Please describe.
Current schema update script looks like this
[Test]
public void UpdateSchema()
{
var configuration = new MySessionFactoryBuilder(/* IConfiguration */)).CreateConfiguration();
Configuration config = null;
configuration.ExposeConfiguration(c => config = c);
configuration.BuildSessionFactory();
config.CreateIndexesForForeignKeys();
var updater = new NHibernate.Tool.hbm2ddl.SchemaUpdate(config);
updater.Execute(true, true);
}
Describe the solution you'd like
This code can be moved to Simplify.FluentNHibernate as an extension method for FluentConfiguration
with ability to extend Configuration