File tree Expand file tree Collapse file tree 1 file changed +6
-1
lines changed
Src/NHibernate.Envers.Tests/NetSpecific/Integration/ManyToOne/LazyProperty Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Original file line number Diff line number Diff line change 11using System . Linq ;
22using NUnit . Framework ;
3+ using SharpTestsEx ;
34
45namespace NHibernate . Envers . Tests . NetSpecific . Integration . ManyToOne . LazyProperty
56{
@@ -25,16 +26,20 @@ protected override void Initialize()
2526 [ Test ]
2627 public void SavePersonProxyForFieldInterceptor ( )
2728 {
29+ long carId ;
2830 using ( var tx = Session . BeginTransaction ( ) )
2931 {
3032 var pers = Session . Query < Person > ( ) . Single ( x => x . Id == id_pers1 ) ;
3133 var car = new Car
3234 {
3335 Owner = pers
3436 } ;
35- id_pers1 = ( long ) Session . Save ( car ) ;
37+ carId = ( long ) Session . Save ( car ) ;
3638 tx . Commit ( ) ;
3739 }
40+
41+ AuditReader ( ) . Find < Car > ( carId , 2 ) . Owner . Name
42+ . Should ( ) . Be . EqualTo ( "Hernan" ) ;
3843 }
3944 }
4045}
You can’t perform that action at this time.
0 commit comments