public void PersistSimpleDomainObject() { var simpleDomainObject = new SimpleDomainObject { Name = "Hello World." }; var simpleRepository = new RepositoryWithIntId<SimpleDomainObject>(Session); using (var transaction = Session.BeginTransaction()) { simpleRepository.Insert(simpleDomainObject); transaction.Commit(); } Assert.IsNotNull(simpleDomainObject.Id); }
public void PersistOtherDomainObject() { var otherDomainObject = new OtherDomainObject { Name = "Hello World." }; var otherRepository = new RepositoryWithIntId<OtherDomainObject>(Session); using (var transaction = Session.BeginTransaction()) { otherRepository.Insert(otherDomainObject); transaction.Commit(); } Assert.IsNotNull(otherDomainObject.Id); }