/// <summary> /// Initializes the <see cref = "NHConfiguration" /> class. /// </summary> static NHConfiguration() { section = ConfigurationManager.GetSection ( "dexter.nhibernate.core.configurationSection" ) as NHConfigurationSection; if ( section == null ) throw new ConfigurationErrorsException ( "Maintenance section not found in the configuration file." ); ConnectionString = ConfigurationManager.ConnectionStrings [ section.ConnectionStringName ].ConnectionString; }
public void FixtureSetUp() { NHibernate.NHConfigurationSection section = new NHibernate.NHConfigurationSection(); section.ConnectionStringName = SqlLiteConnectionString; section.DatabaseType = "SqlLite"; RestoreNHibernateSessionManager = NHibernate.NHelper.OverrideSessionFactory(section); if (RecreateDb) NHibernate.NHelper.InitializeSchema(); }