You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/NHibernate.Test/SecondLevelCacheTest/QueryCacheFixture.cs
+8-8Lines changed: 8 additions & 8 deletions
Original file line number
Diff line number
Diff line change
@@ -257,7 +257,7 @@ public void SimpleProjections()
257
257
tx.Commit();
258
258
}
259
259
260
-
Assert.That(qs.CacheHitCount,Is.EqualTo(1),"hit count should not go up since we are adding a resulttransformer");
260
+
Assert.That(qs.CacheHitCount,Is.EqualTo(2),"hit count should go up since the cache contains the result before the possible application of a resulttransformer");
261
261
262
262
using(ISessions=OpenSession())
263
263
using(ITransactiontx=s.BeginTransaction())
@@ -266,7 +266,7 @@ public void SimpleProjections()
266
266
tx.Commit();
267
267
}
268
268
269
-
Assert.That(qs.CacheHitCount,Is.EqualTo(2),"hit count should go up since we are using the same resulttransformer");
269
+
Assert.That(qs.CacheHitCount,Is.EqualTo(3),"hit count should go up since we are using the same resulttransformer");
270
270
using(ISessions=OpenSession())
271
271
using(ITransactiontx=s.BeginTransaction())
272
272
{
@@ -277,8 +277,8 @@ public void SimpleProjections()
277
277
tx.Commit();
278
278
}
279
279
280
-
Assert.That(qs.CacheHitCount,Is.EqualTo(3));
281
-
Assert.That(qs.CacheMissCount,Is.EqualTo(3));
280
+
Assert.That(qs.CacheHitCount,Is.EqualTo(4));
281
+
Assert.That(qs.CacheMissCount,Is.EqualTo(2));
282
282
283
283
Thread.Sleep(200);
284
284
@@ -294,10 +294,10 @@ public void SimpleProjections()
294
294
tx.Commit();
295
295
}
296
296
297
-
Assert.That(qs.CacheHitCount,Is.EqualTo(3));
298
-
Assert.That(qs.CacheMissCount,Is.EqualTo(4));
299
-
Assert.That(qs.CachePutCount,Is.EqualTo(4));
300
-
Assert.That(qs.ExecutionCount,Is.EqualTo(4));
297
+
Assert.That(qs.CacheHitCount,Is.EqualTo(4));
298
+
Assert.That(qs.CacheMissCount,Is.EqualTo(3));
299
+
Assert.That(qs.CachePutCount,Is.EqualTo(3));
300
+
Assert.That(qs.ExecutionCount,Is.EqualTo(3));
301
301
Assert.That(es.FetchCount,Is.EqualTo(0));//check that it was being cached
0 commit comments