protected override void OnSetUp() { using (ISession s = OpenSession()) { using (ITransaction tx = s.BeginTransaction()) { var entity = new EntityWithTypeProperty {Id = 1, TypeValue = typeof (File)}; s.Save(entity); entity = new EntityWithTypeProperty {Id = 2, TypeValue = typeof (DummyEntity)}; s.Save(entity); tx.Commit(); } } }
protected override void OnSetUp() { using (ISession s = OpenSession()) { using (ITransaction tx = s.BeginTransaction()) { var entity = new EntityWithTypeProperty { Id = 1, TypeValue = typeof(File) }; s.Save(entity); entity = new EntityWithTypeProperty { Id = 2, TypeValue = typeof(DummyEntity) }; s.Save(entity); tx.Commit(); } } }