-
Notifications
You must be signed in to change notification settings - Fork 29.7k
Add tests for shortcuts.dart API examples. #147433
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add tests for shortcuts.dart API examples. #147433
Conversation
bleroux
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! Thanks for the contribution.
d371abf to
756a7d8
Compare
756a7d8 to
f74e6a1
Compare
|
Hi @bleroux @TahaTesser thanks a lot for the review! |
|
@TahaTesser thanks for the replies and examples. I updated the tests according to your feedback. Could you please take a look again? |
TahaTesser
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! With updated titles
| expect(find.text('count: 0'), findsOneWidget); | ||
| }); | ||
|
|
||
| testWidgets('updates counter on arrowUp and arrowDown press', (WidgetTester tester) async { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| testWidgets('updates counter on arrowUp and arrowDown press', (WidgetTester tester) async { | |
| testWidgets(' Up and down arrow press updates counter', (WidgetTester tester) async { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Similar title in other test
| import 'package:flutter_test/flutter_test.dart'; | ||
|
|
||
| void main() { | ||
| testWidgets('displays correct labels', (WidgetTester tester) async { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| testWidgets('displays correct labels', (WidgetTester tester) async { | |
| testWidgets('Verify correct labels are displayed', (WidgetTester tester) async { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Similar title in other test
|
@bleroux @TahaTesser thanks for the review! |
flutter/flutter@04424e1...7920a52 2024-05-07 [email protected] Add tests for callback_shortcuts.0.dart API example. (flutter/flutter#147536) 2024-05-07 [email protected] Improve Android SDK and NDK mistmatch warning message (flutter/flutter#147809) 2024-05-07 [email protected] Add tests for shortcuts.dart API examples. (flutter/flutter#147433) 2024-05-07 [email protected] Added missing tests for ButtonStyle example (flutter/flutter#147457) 2024-05-07 [email protected] Roll Flutter Engine from ece1d686e3ba to 150f694a7816 (1 revision) (flutter/flutter#147912) 2024-05-07 [email protected] DropdownMenu cleanup (flutter/flutter#147860) 2024-05-07 [email protected] Roll Flutter Engine from 80470584e1e1 to ece1d686e3ba (1 revision) (flutter/flutter#147910) 2024-05-07 [email protected] Roll Flutter Engine from b7bfd94af743 to 80470584e1e1 (1 revision) (flutter/flutter#147906) 2024-05-07 [email protected] Roll Flutter Engine from b64e2300bcd0 to b7bfd94af743 (1 revision) (flutter/flutter#147905) 2024-05-07 [email protected] fix MenuItemButton if child is null (flutter/flutter#147485) 2024-05-07 [email protected] Fix document generation, eliminate template support from snippets tool. (flutter/flutter#147893) 2024-05-07 [email protected] Roll Flutter Engine from 4cb9e02c06ce to b64e2300bcd0 (1 revision) (flutter/flutter#147904) 2024-05-07 [email protected] test focus example 0 (flutter/flutter#147564) 2024-05-07 [email protected] Roll Flutter Engine from 422f92b992c5 to 4cb9e02c06ce (1 revision) (flutter/flutter#147899) 2024-05-06 [email protected] Roll pub packages (flutter/flutter#147896) 2024-05-06 [email protected] Roll Flutter Engine from 463ff7d2d4d5 to 422f92b992c5 (5 revisions) (flutter/flutter#147895) 2024-05-06 [email protected] MultiSelectableSelectionContainerDelegate documentation fixes. (flutter/flutter#147843) 2024-05-06 [email protected] Roll pub packages (flutter/flutter#147891) 2024-05-06 49699333+dependabot[bot]@users.noreply.github.com Bump actions/checkout from 4.1.4 to 4.1.5 (flutter/flutter#147888) 2024-05-06 [email protected] Fix janks and memory leaks in `CupertinoPageTransition` and `CupertinoFullscreenDialogTransition` (flutter/flutter#146999) 2024-05-06 [email protected] Roll Flutter Engine from 960a0c8fecbe to 463ff7d2d4d5 (1 revision) (flutter/flutter#147886) 2024-05-06 [email protected] Roll Flutter Engine from 70cc300f9ad8 to 960a0c8fecbe (1 revision) (flutter/flutter#147884) 2024-05-06 [email protected] [new gallery] Reisze gallery images (flutter/flutter#147882) 2024-05-06 [email protected] Roll Flutter Engine from d0f99b35eac6 to 70cc300f9ad8 (1 revision) (flutter/flutter#147880) 2024-05-06 [email protected] Fix leak in a test. (flutter/flutter#147846) 2024-05-06 [email protected] Roll Flutter Engine from a30ae7729c95 to d0f99b35eac6 (3 revisions) (flutter/flutter#147878) 2024-05-06 [email protected] Roll Packages from f4719ca to 2dfe645 (3 revisions) (flutter/flutter#147866) If this roll has caused a breakage, revert this CL and stop the roller using the controls here: https://autoroll.skia.org/r/flutter-packages Please CC [email protected],[email protected],[email protected] on the revert to ensure that a human is aware of the problem. To file a bug in Packages: https://github.com/flutter/flutter/issues/new/choose To report a problem with the AutoRoller itself, please file a bug: https://issues.skia.org/issues/new?component=1389291&template=1850622 Documentation for the AutoRoller is here: https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
flutter/flutter@04424e1...7920a52 2024-05-07 [email protected] Add tests for callback_shortcuts.0.dart API example. (flutter/flutter#147536) 2024-05-07 [email protected] Improve Android SDK and NDK mistmatch warning message (flutter/flutter#147809) 2024-05-07 [email protected] Add tests for shortcuts.dart API examples. (flutter/flutter#147433) 2024-05-07 [email protected] Added missing tests for ButtonStyle example (flutter/flutter#147457) 2024-05-07 [email protected] Roll Flutter Engine from ece1d686e3ba to 150f694a7816 (1 revision) (flutter/flutter#147912) 2024-05-07 [email protected] DropdownMenu cleanup (flutter/flutter#147860) 2024-05-07 [email protected] Roll Flutter Engine from 80470584e1e1 to ece1d686e3ba (1 revision) (flutter/flutter#147910) 2024-05-07 [email protected] Roll Flutter Engine from b7bfd94af743 to 80470584e1e1 (1 revision) (flutter/flutter#147906) 2024-05-07 [email protected] Roll Flutter Engine from b64e2300bcd0 to b7bfd94af743 (1 revision) (flutter/flutter#147905) 2024-05-07 [email protected] fix MenuItemButton if child is null (flutter/flutter#147485) 2024-05-07 [email protected] Fix document generation, eliminate template support from snippets tool. (flutter/flutter#147893) 2024-05-07 [email protected] Roll Flutter Engine from 4cb9e02c06ce to b64e2300bcd0 (1 revision) (flutter/flutter#147904) 2024-05-07 [email protected] test focus example 0 (flutter/flutter#147564) 2024-05-07 [email protected] Roll Flutter Engine from 422f92b992c5 to 4cb9e02c06ce (1 revision) (flutter/flutter#147899) 2024-05-06 [email protected] Roll pub packages (flutter/flutter#147896) 2024-05-06 [email protected] Roll Flutter Engine from 463ff7d2d4d5 to 422f92b992c5 (5 revisions) (flutter/flutter#147895) 2024-05-06 [email protected] MultiSelectableSelectionContainerDelegate documentation fixes. (flutter/flutter#147843) 2024-05-06 [email protected] Roll pub packages (flutter/flutter#147891) 2024-05-06 49699333+dependabot[bot]@users.noreply.github.com Bump actions/checkout from 4.1.4 to 4.1.5 (flutter/flutter#147888) 2024-05-06 [email protected] Fix janks and memory leaks in `CupertinoPageTransition` and `CupertinoFullscreenDialogTransition` (flutter/flutter#146999) 2024-05-06 [email protected] Roll Flutter Engine from 960a0c8fecbe to 463ff7d2d4d5 (1 revision) (flutter/flutter#147886) 2024-05-06 [email protected] Roll Flutter Engine from 70cc300f9ad8 to 960a0c8fecbe (1 revision) (flutter/flutter#147884) 2024-05-06 [email protected] [new gallery] Reisze gallery images (flutter/flutter#147882) 2024-05-06 [email protected] Roll Flutter Engine from d0f99b35eac6 to 70cc300f9ad8 (1 revision) (flutter/flutter#147880) 2024-05-06 [email protected] Fix leak in a test. (flutter/flutter#147846) 2024-05-06 [email protected] Roll Flutter Engine from a30ae7729c95 to d0f99b35eac6 (3 revisions) (flutter/flutter#147878) 2024-05-06 [email protected] Roll Packages from f4719ca to 2dfe645 (3 revisions) (flutter/flutter#147866) If this roll has caused a breakage, revert this CL and stop the roller using the controls here: https://autoroll.skia.org/r/flutter-packages Please CC [email protected],[email protected],[email protected] on the revert to ensure that a human is aware of the problem. To file a bug in Packages: https://github.com/flutter/flutter/issues/new/choose To report a problem with the AutoRoller itself, please file a bug: https://issues.skia.org/issues/new?component=1389291&template=1850622 Documentation for the AutoRoller is here: https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
This PR contributes to #130459
Description
examples/api/lib/widgets/shortcuts/shortcuts.0.dartexamples/api/lib/widgets/shortcuts/shortcuts.1.dartPre-launch Checklist
///).