//[ExpectedException(typeof(CommitFailedException))]
        public void CreatePerson()
        {
            var tran = this.DAO.GetTransactionProvider();
            try
            {
                tran.BeginTransaction();

                Person p = new Person { Name = "James", Surname = "Brown11" };
                Person person = this.DAO.MakePersistent(p, true);                   //uses identity algorithm
                Assert.IsNotNull(person);

                tran.CommitTransaction();

                Assert.AreNotEqual(person.ID, 0);
            }
            catch (Exception ex)
            {
                tran.RollbackTransaction(ex);
                throw ex;
            }
        }
        public void TestCreatePerson2()
        {
            var tranProvider = this.DAO.GetTransactionProvider();
            try
            {
                tranProvider.BeginTransaction();

                Person p = new Person { Name = "James", Surname = "Brown6" };
                var person = this.DAO.MakePersistent(p, "210");
                //Assert.IsNotNull(person);

                //var ret = this.DAO.FindBy<Person>("210");
                //Assert.IsNotNull(ret);

                tranProvider.CommitTransaction();
            }
            catch (Exception ex)
            {
                tranProvider.RollbackTransaction(ex);
                throw;
            }
        }