-
Notifications
You must be signed in to change notification settings - Fork 26.7k
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
refactor flutter driver command extensions #148180
base: master
Are you sure you want to change the base?
Conversation
It looks like this pull request may not have tests. Please make sure to add tests before merging. If you need an exemption to this rule, contact "@test-exemption-reviewer" in the #hackers channel in Chat (don't just cc them here, they won't see it! Use Discord!). If you are not sure if you need tests, consider this rule of thumb: the purpose of a test is to make sure someone doesn't accidentally revert the fix. Ask yourself, is there anything in your PR that you feel it is important we not accidentally revert back to how it was before your fix? Reviewers: Read the Tree Hygiene page and make sure this patch meets those guidelines before LGTMing. |
*Total -- 695.40kb -> 543.96kb (21.78%) /dev/tools/vitool/test_assets/empty_svg_2_100x50.svg -- 0.18kb -> 0.08kb (56.04%) /examples/api/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_512.png -- 14.45kb -> 9.69kb (32.93%) /dev/a11y_assessments/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_512.png -- 14.45kb -> 9.69kb (32.93%) /examples/image_list/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_512.png -- 14.45kb -> 9.69kb (32.93%) /dev/manual_tests/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_512.png -- 14.45kb -> 9.69kb (32.93%) /dev/integration_tests/ui/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_512.png -- 14.45kb -> 9.69kb (32.93%) /dev/integration_tests/flutter_gallery/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_512.png -- 14.45kb -> 9.69kb (32.93%) /examples/hello_world/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_512.png -- 14.45kb -> 9.69kb (32.93%) /examples/api/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_1024.png -- 45.89kb -> 31.58kb (31.18%) /examples/hello_world/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_1024.png -- 45.89kb -> 31.58kb (31.18%) /dev/integration_tests/ui/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_1024.png -- 45.89kb -> 31.58kb (31.18%) /dev/a11y_assessments/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_1024.png -- 45.89kb -> 31.58kb (31.18%) /examples/image_list/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_1024.png -- 45.89kb -> 31.58kb (31.18%) /dev/manual_tests/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_1024.png -- 45.89kb -> 31.58kb (31.18%) /dev/integration_tests/flutter_gallery/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_1024.png -- 45.89kb -> 31.58kb (31.18%) /examples/api/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_16.png -- 1.40kb -> 1.00kb (28.62%) /dev/a11y_assessments/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_16.png -- 1.40kb -> 1.00kb (28.62%) /examples/image_list/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_16.png -- 1.40kb -> 1.00kb (28.62%) /dev/manual_tests/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_16.png -- 1.40kb -> 1.00kb (28.62%) /examples/hello_world/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_16.png -- 1.40kb -> 1.00kb (28.62%) /dev/integration_tests/flutter_gallery/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_16.png -- 1.40kb -> 1.00kb (28.62%) /dev/integration_tests/ui/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_16.png -- 1.40kb -> 1.00kb (28.62%) /dev/a11y_assessments/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_256.png -- 5.79kb -> 4.27kb (26.23%) /examples/hello_world/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_256.png -- 5.79kb -> 4.27kb (26.23%) /dev/integration_tests/flutter_gallery/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_256.png -- 5.79kb -> 4.27kb (26.23%) /dev/integration_tests/ui/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_256.png -- 5.79kb -> 4.27kb (26.23%) /examples/image_list/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_256.png -- 5.79kb -> 4.27kb (26.23%) /examples/api/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_256.png -- 5.79kb -> 4.27kb (26.23%) /dev/manual_tests/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_256.png -- 5.79kb -> 4.27kb (26.23%) /examples/api/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_128.png -- 3.20kb -> 2.60kb (18.77%) /dev/a11y_assessments/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_128.png -- 3.20kb -> 2.60kb (18.77%) /dev/manual_tests/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_128.png -- 3.20kb -> 2.60kb (18.77%) /examples/hello_world/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_128.png -- 3.20kb -> 2.60kb (18.77%) /examples/image_list/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_128.png -- 3.20kb -> 2.60kb (18.77%) /dev/integration_tests/flutter_gallery/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_128.png -- 3.20kb -> 2.60kb (18.77%) /dev/integration_tests/ui/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_128.png -- 3.20kb -> 2.60kb (18.77%) /dev/tools/vitool/test_assets/illegal_svg_multiple_roots.svg -- 0.10kb -> 0.09kb (12.87%) /dev/tools/vitool/test_assets/empty_svg_1_48x48.svg -- 0.09kb -> 0.08kb (12.77%) /dev/tools/vitool/test_assets/bar_group_opacity.svg -- 0.22kb -> 0.20kb (11.01%) /dev/tools/vitool/test_assets/bars_group.svg -- 0.30kb -> 0.26kb (10.86%) /dev/tools/vitool/test_assets/bar_group_scale.svg -- 0.23kb -> 0.21kb (9.62%) /dev/tools/vitool/test_assets/bar_group_translate.svg -- 0.24kb -> 0.21kb (9.5%) /dev/tools/vitool/test_assets/leading_space_path_command.svg -- 0.13kb -> 0.12kb (9.49%) /dev/tools/vitool/test_assets/illegal_transform.svg -- 0.24kb -> 0.22kb (9.39%) /dev/tools/vitool/test_assets/bar_group_rotate_scale.svg -- 0.25kb -> 0.23kb (8.98%) /dev/tools/vitool/test_assets/illegal_path.svg -- 0.14kb -> 0.13kb (8.33%) /dev/tools/vitool/test_assets/horizontal_bar.svg -- 0.18kb -> 0.17kb (7.14%) /dev/tools/vitool/test_assets/horizontal_bar_relative.svg -- 0.18kb -> 0.17kb (7.1%) /dev/tools/vitool/test_assets/close_path_in_middle.svg -- 0.19kb -> 0.18kb (6.6%) /examples/image_list/images/coast.jpg -- 197.60kb -> 197.60kb (0%) Signed-off-by: ImgBotApp <ImgBotHelp@gmail.com>
Where did you remove the unnecessary async/await keywords |
yep, you're right, there aren't any async/await keywords in this code. maybe i got confused by another code snippet. this code has changes only in syntactic sugar for simplification, using arrow functions ( thanks! |
@override | ||
Command deserialize(Map<String, String> params, DeserializeFinderFactory finderFactory, DeserializeCommandFactory commandFactory) { | ||
return StubNestedCommand.deserialize(params, finderFactory); | ||
} | ||
Command deserialize(Map<String, String> params, DeserializeFinderFactory finderFactory, DeserializeCommandFactory commandFactory) => | ||
StubNestedCommand.deserialize(params, finderFactory); |
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.
This looks quite a bit nicer!
Unfortunately, the Flutter repo has a style guideline specifically for this situation:
only use
=>
when everything, including the function declaration, fits on a single line.
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.
This looks quite a bit nicer!
Unfortunately, the Flutter repo has a style guideline specifically for this situation:
only use
=>
when everything, including the function declaration, fits on a single line.
thank you for the info.
[ImgBot] Optimize images
Does @ImgBotApp have an option to output the images in |
This PR refactors the
StubNestedCommandExtension
andStubProberCommandExtension
classes, optimizing code structure.Improves code readability and maintainability without altering the functionality of the classes.