@@ -129,6 +129,7 @@ public async Task QueryOverComponentWithANullPropertyAsync()
129
129
. Where ( p => p . Connection == componentToCompare )
130
130
. SingleOrDefaultAsync < Person > ( ) ) ;
131
131
132
+ Assert . That ( sally , Is . Not . Null ) ;
132
133
Assert . That ( sally . Name , Is . EqualTo ( "Sally" ) ) ;
133
134
Assert . That ( sally . Connection . PortName , Is . Null ) ;
134
135
}
@@ -164,6 +165,7 @@ public async Task QueryAgainstComponentWithANullPropertyUsingCriteriaAsync()
164
165
. Add ( Restrictions . Eq ( "Connection" , componentToCompare ) )
165
166
. UniqueResultAsync < Person > ( ) ) ;
166
167
168
+ Assert . That ( sally , Is . Not . Null ) ;
167
169
Assert . That ( sally . Name , Is . EqualTo ( "Sally" ) ) ;
168
170
Assert . That ( sally . Connection . PortName , Is . Null ) ;
169
171
}
@@ -187,6 +189,7 @@ public async Task CachedQueryMissesWithDifferentNotNullComponentAsync()
187
189
. SetCacheable ( true )
188
190
. UniqueResultAsync < CachedPerson > ( ) ) ;
189
191
192
+ Assert . That ( cached , Is . Not . Null ) ;
190
193
Assert . That ( cached . Name , Is . EqualTo ( "CachedNull" ) ) ;
191
194
Assert . That ( cached . Connection . PortName , Is . Null ) ;
192
195
@@ -234,6 +237,7 @@ public async Task CachedQueryMissesWithDifferentNullComponentAsync()
234
237
. SetCacheable ( true )
235
238
. UniqueResultAsync < CachedPerson > ( ) ) ;
236
239
240
+ Assert . That ( cached , Is . Not . Null ) ;
237
241
Assert . That ( cached . Name , Is . EqualTo ( "CachedNotNull" ) ) ;
238
242
Assert . That ( cached . Connection . PortName , Is . Not . Null ) ;
239
243
@@ -281,6 +285,7 @@ public async Task CachedQueryAgainstComponentWithANullPropertyUsingCriteriaAsync
281
285
. SetCacheable ( true )
282
286
. UniqueResultAsync < CachedPerson > ( ) ) ;
283
287
288
+ Assert . That ( cached , Is . Not . Null ) ;
284
289
Assert . That ( cached . Name , Is . EqualTo ( "CachedNull" ) ) ;
285
290
Assert . That ( cached . Connection . PortName , Is . Null ) ;
286
291
@@ -303,6 +308,7 @@ public async Task CachedQueryAgainstComponentWithANullPropertyUsingCriteriaAsync
303
308
. SetCacheable ( true )
304
309
. UniqueResultAsync < CachedPerson > ( ) ) ;
305
310
311
+ Assert . That ( cached , Is . Not . Null ) ;
306
312
Assert . That ( cached . Name , Is . EqualTo ( "CachedNull" ) ) ;
307
313
Assert . That ( cached . Connection . PortName , Is . Null ) ;
308
314
@@ -332,6 +338,7 @@ public async Task QueryOverANullComponentPropertyAsync()
332
338
. And ( p => p . Connection . ConnectionType == "http" )
333
339
. SingleOrDefaultAsync < Person > ( ) ) ;
334
340
341
+ Assert . That ( sally , Is . Not . Null ) ;
335
342
Assert . That ( sally . Name , Is . EqualTo ( "Sally" ) ) ;
336
343
Assert . That ( sally . Connection . PortName , Is . Null ) ;
337
344
}
@@ -349,6 +356,7 @@ public async Task QueryAgainstANullComponentPropertyUsingCriteriaApiAsync()
349
356
. Add ( Restrictions . Eq ( "Connection.ConnectionType" , "http" ) )
350
357
. UniqueResultAsync < Person > ( ) ) ;
351
358
359
+ Assert . That ( sally , Is . Not . Null ) ;
352
360
Assert . That ( sally . Name , Is . EqualTo ( "Sally" ) ) ;
353
361
Assert . That ( sally . Connection . PortName , Is . Null ) ;
354
362
}
0 commit comments