testWidgets("FocusScope doesn't update the focusNode attributes when the widget updates if withExternalFocusNode is used",(WidgetTestertester)async{
testWidgetsWithLeakTracking("FocusScope doesn't update the focusNode attributes when the widget updates if withExternalFocusNode is used",(WidgetTestertester)async{
testWidgets("Focus doesn't update the focusNode attributes when the widget updates if withExternalFocusNode is used",(WidgetTestertester)async{
testWidgetsWithLeakTracking("Focus doesn't update the focusNode attributes when the widget updates if withExternalFocusNode is used",(WidgetTestertester)async{
// Regression test for https://github.com/flutter/flutter/issues/92693
testWidgets('Setting parent FocusScope.canRequestFocus to false, does not set descendant Focus._internalNode._canRequestFocus to false',(WidgetTestertester)async{
testWidgetsWithLeakTracking('Setting parent FocusScope.canRequestFocus to false, does not set descendant Focus._internalNode._canRequestFocus to false',(WidgetTestertester)async{
testWidgets("Descendants of FocusTraversalGroup aren't traversable if descendantsAreTraversable is false.",(WidgetTestertester)async{
testWidgetsWithLeakTracking("Descendants of FocusTraversalGroup aren't traversable if descendantsAreTraversable is false.",(WidgetTestertester)async{
finalFocusNodenode1=FocusNode();
addTearDown(node1.dispose);
finalFocusNodenode2=FocusNode();
addTearDown(node2.dispose);
awaittester.pumpWidget(
FocusTraversalGroup(
...
...
@@ -2779,9 +2895,11 @@ void main() {
expect(node2.hasPrimaryFocus,isFalse);
});
testWidgets("FocusTraversalGroup with skipTraversal for all descendants set to true doesn't cause an exception.",(WidgetTestertester)async{
testWidgetsWithLeakTracking("FocusTraversalGroup with skipTraversal for all descendants set to true doesn't cause an exception.",(WidgetTestertester)async{
finalFocusNodenode1=FocusNode();
addTearDown(node1.dispose);
finalFocusNodenode2=FocusNode();
addTearDown(node2.dispose);
awaittester.pumpWidget(
FocusTraversalGroup(
...
...
@@ -2815,11 +2933,13 @@ void main() {
expect(node2.hasPrimaryFocus,isFalse);
});
testWidgets("Nested FocusTraversalGroup with unfocusable children doesn't assert.",(WidgetTestertester)async{
testWidgetsWithLeakTracking("Nested FocusTraversalGroup with unfocusable children doesn't assert.",(WidgetTestertester)async{
finalGlobalKeykey1=GlobalKey(debugLabel:'1');
finalGlobalKeykey2=GlobalKey(debugLabel:'2');
finalFocusNodefocusNode=FocusNode();
addTearDown(focusNode.dispose);
bool?gotFocus;
awaittester.pumpWidget(
FocusTraversalGroup(
child:Column(
...
...
@@ -2864,9 +2984,11 @@ void main() {
expect(unfocusableNode.hasFocus,isFalse);
});
testWidgets("Empty FocusTraversalGroup doesn't cause an exception.",(WidgetTestertester)async{
testWidgetsWithLeakTracking("Empty FocusTraversalGroup doesn't cause an exception.",(WidgetTestertester)async{