From: Michael D. <mik...@us...> - 2004-11-28 03:27:58
|
Update of /cvsroot/nhibernate/nhibernate/src/NHibernate.Test In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv7017/src/NHibernate.Test Modified Files: MultiTableTest.cs Log Message: fix for NH-158 Index: MultiTableTest.cs =================================================================== RCS file: /cvsroot/nhibernate/nhibernate/src/NHibernate.Test/MultiTableTest.cs,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** MultiTableTest.cs 18 Nov 2004 02:46:59 -0000 1.6 --- MultiTableTest.cs 28 Nov 2004 03:13:43 -0000 1.7 *************** *** 650,653 **** --- 650,673 ---- } + [Test] + public void DynamicUpdate() + { + ISession s = sessions.OpenSession(); + Simple simple = new Simple(); + + simple.Name = "saved"; + object id = s.Save( simple ); + s.Flush(); + + simple.Name = "updated"; + s.Flush(); + s.Close(); + + s = sessions.OpenSession(); + simple = (Simple)s.Load( typeof(Simple), id ); + Assert.AreEqual( "updated", simple.Name, "name should have been updated" ); + s.Close(); + } + } } |