Use case
The WidgetTesterCallback typedef currently names its parameter widgetTester.
In practice, Flutter documentation, tutorials, and the vast majority of real-world
test code use the shorter and idiomatic name tester. Because IDEs use the
typedef’s parameter name for autocomplete, developers frequently need to manually
rename widgetTester to tester when writing widget tests.
This creates minor but repeated friction and inconsistency with established
Flutter conventions. There is no functional issue, but it negatively impacts
developer experience and API consistency.
Proposal
Rename the parameter in the WidgetTesterCallback typedef from widgetTester
to tester.
Current:
typedef WidgetTesterCallback = Future<void> Function(WidgetTester widgetTester);
Proposed:
typedef WidgetTesterCallback = Future<void> Function(WidgetTester tester);
This change is non-breaking, as parameter names in function typedefs are not part
of the public API contract.
Use case
The
WidgetTesterCallbacktypedef currently names its parameterwidgetTester.In practice, Flutter documentation, tutorials, and the vast majority of real-world
test code use the shorter and idiomatic name
tester. Because IDEs use thetypedef’s parameter name for autocomplete, developers frequently need to manually
rename
widgetTestertotesterwhen writing widget tests.This creates minor but repeated friction and inconsistency with established
Flutter conventions. There is no functional issue, but it negatively impacts
developer experience and API consistency.
Proposal
Rename the parameter in the
WidgetTesterCallbacktypedef fromwidgetTesterto
tester.Current:
Proposed:
This change is non-breaking, as parameter names in function typedefs are not part
of the public API contract.