-
Notifications
You must be signed in to change notification settings - Fork 3.6k
[two_dimensional_scrollables] Update test for deprecation #10525
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
[two_dimensional_scrollables] Update test for deprecation #10525
Conversation
Updates tests that use the deprecated `Color.withOpacity` to use `Color.withValues(alpha:)` instead. Fixes flutter/flutter#159733
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.
Code Review
This pull request correctly updates the test files to replace the deprecated Color.withOpacity with the recommended Color.withValues(alpha:). The changes are straightforward and address the deprecation as intended. I have added one comment regarding code duplication, suggesting the extraction of a repeated color value into a variable to improve maintainability.
| height: 200, | ||
| width: 200, | ||
| color: Colors.grey.withOpacity(0.5), | ||
| color: Colors.grey.withValues(alpha: 0.5), |
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.
Piinks
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! Thank you!
flutter/packages@148dcd2...8cb4903 2025-12-02 [email protected] Remove `no_adjacent_strings_in_list` from enabled lint rules. (flutter/packages#7878) 2025-12-02 [email protected] Roll Flutter from 05d6005 to 5545bb3 (28 revisions) (flutter/packages#10551) 2025-12-02 [email protected] [two_dimensional_scrollables] Update test for deprecation (flutter/packages#10525) 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-flutter-autoroll Please CC [email protected] on the revert to ensure that a human is aware of the problem. To file a bug in Flutter: 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
…r#179407) flutter/packages@148dcd2...8cb4903 2025-12-02 [email protected] Remove `no_adjacent_strings_in_list` from enabled lint rules. (flutter/packages#7878) 2025-12-02 [email protected] Roll Flutter from 05d6005 to 5545bb3 (28 revisions) (flutter/packages#10551) 2025-12-02 [email protected] [two_dimensional_scrollables] Update test for deprecation (flutter/packages#10525) 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-flutter-autoroll Please CC [email protected] on the revert to ensure that a human is aware of the problem. To file a bug in Flutter: 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
Updates tests that use the deprecated
Color.withOpacityto useColor.withValues(alpha:)instead.Fixes flutter/flutter#159733
Pre-Review Checklist
[shared_preferences]pubspec.yamlwith an appropriate new version according to the pub versioning philosophy, or I have commented below to indicate which version change exemption this PR falls under1.CHANGELOG.mdto add a description of the change, following repository CHANGELOG style, or I have commented below to indicate which CHANGELOG exemption this PR falls under1.///).Footnotes
Regular contributors who have demonstrated familiarity with the repository guidelines only need to comment if the PR is not auto-exempted by repo tooling. ↩ ↩2 ↩3