@@ -45,7 +45,7 @@ await App.DispatcherQueue.EnqueueAsync(async () =>
45
45
await SetTestContentAsync ( treeRoot ) ;
46
46
47
47
// Main Test
48
- var textBlock = treeRoot . FindDescendantByName ( "TargetElement" ) ;
48
+ var textBlock = treeRoot . FindDescendant ( "TargetElement" ) ;
49
49
50
50
Assert . IsNotNull ( textBlock , "Expected to find something." ) ;
51
51
Assert . IsInstanceOfType ( textBlock , typeof ( TextBlock ) , "Didn't find expected typed element." ) ;
@@ -80,7 +80,7 @@ await App.DispatcherQueue.EnqueueAsync(async () =>
80
80
await SetTestContentAsync ( treeRoot ) ;
81
81
82
82
// Main Test
83
- var textBlock = treeRoot . FindDescendantByName ( "TargetElement" ) ;
83
+ var textBlock = treeRoot . FindDescendant ( "TargetElement" ) ;
84
84
85
85
Assert . IsNull ( textBlock , "Didn't expect to find anything." ) ;
86
86
} ) ;
@@ -220,7 +220,7 @@ await App.DispatcherQueue.EnqueueAsync(async () =>
220
220
await SetTestContentAsync ( treeRoot ) ;
221
221
222
222
// Main Test
223
- var textBlocks = treeRoot . FindDescendants < TextBlock > ( ) ;
223
+ var textBlocks = treeRoot . FindDescendants ( ) . OfType < TextBlock > ( ) ;
224
224
225
225
Assert . IsNotNull ( textBlocks , "Expected to find something." ) ;
226
226
@@ -267,7 +267,7 @@ await App.DispatcherQueue.EnqueueAsync(async () =>
267
267
await SetTestContentAsync ( treeRoot ) ;
268
268
269
269
// Main Test
270
- var thing = treeRoot . FindDescendants < UniformGrid > ( ) ;
270
+ var thing = treeRoot . FindDescendants ( ) . OfType < UniformGrid > ( ) ;
271
271
272
272
Assert . IsNotNull ( thing , "Expected to find something." ) ;
273
273
@@ -411,7 +411,7 @@ await App.DispatcherQueue.EnqueueAsync(async () =>
411
411
Assert . IsNotNull ( startingPoint , "Could not find starting element." ) ;
412
412
413
413
// Main Test
414
- var grid = startingPoint . FindAscendantByName ( "TargetElement" ) ;
414
+ var grid = startingPoint . FindAscendant ( "TargetElement" ) ;
415
415
416
416
Assert . IsNotNull ( grid , "Expected to find Grid" ) ;
417
417
Assert . AreEqual ( targetGrid , grid , "Grid didn't match expected." ) ;
@@ -458,7 +458,7 @@ await App.DispatcherQueue.EnqueueAsync(async () =>
458
458
Assert . IsNotNull ( startingPoint , "Could not find starting element." ) ;
459
459
460
460
// Main Test
461
- var grid = startingPoint . FindAscendantByName ( "TargetElement" ) ;
461
+ var grid = startingPoint . FindAscendant ( "TargetElement" ) ;
462
462
463
463
Assert . IsNull ( grid , "Didn't expect to find anything." ) ;
464
464
} ) ;
0 commit comments