File tree Expand file tree Collapse file tree 2 files changed +4
-6
lines changed
NHibernate.Test/SystemTransactions Expand file tree Collapse file tree 2 files changed +4
-6
lines changed Original file line number Diff line number Diff line change @@ -65,7 +65,7 @@ public void Rollback()
65
65
{
66
66
}
67
67
Assert . AreEqual ( 0 , interceptor . beforeTransactionCompletionCalled ) ;
68
- Assert . AreEqual ( 2 , interceptor . afterTransactionCompletionCalled ) ;
68
+ Assert . AreEqual ( 1 , interceptor . afterTransactionCompletionCalled ) ;
69
69
}
70
70
71
71
[ Test ]
@@ -109,16 +109,13 @@ public void OneTransactionScopesInsideOneSession()
109
109
}
110
110
111
111
112
- [ Description ( "NH2128" ) ]
112
+ [ Description ( "NH2128, NH3572 " ) ]
113
113
[ Theory ]
114
114
public void ShouldNotifyAfterDistributedTransaction ( bool doCommit )
115
115
{
116
116
// Note: For distributed transaction, calling Close() on the session isn't
117
117
// supported, so we don't need to test that scenario.
118
118
119
- if ( ! doCommit )
120
- Assert . Ignore ( "Rollback on distributed transaction doubles the number of calls to AfterTransactionCompletion - see NH-3572." ) ;
121
-
122
119
var interceptor = new RecordingInterceptor ( ) ;
123
120
ISession s1 = null ;
124
121
ISession s2 = null ;
Original file line number Diff line number Diff line change @@ -147,8 +147,9 @@ void IEnlistmentNotification.Rollback(Enlistment enlistment)
147
147
{
148
148
using ( new SessionIdLoggingContext ( sessionImplementor . SessionId ) )
149
149
{
150
- sessionImplementor . AfterTransactionCompletion ( false , null ) ;
151
150
logger . Debug ( "rolled back DTC transaction" ) ;
151
+ // Currently AfterTransactionCompletion is called by the handler for the TransactionCompleted event.
152
+ //sessionImplementor.AfterTransactionCompletion(false, null);
152
153
enlistment . Done ( ) ;
153
154
IsInActiveTransaction = false ;
154
155
}
You can’t perform that action at this time.
0 commit comments