-
Notifications
You must be signed in to change notification settings - Fork 29.7k
Fix error message for unbounded viewports #123035
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
Conversation
goderbauer
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
|
auto label is removed for flutter/flutter, pr: 123035, due to - The status or check suite Mac customer_testing has failed. Please fix the issues identified (or deflake) before re-applying this label.
|
|
|
||
| testWidgets('Shrinkwrapping viewport asserts bounded cross axis', (WidgetTester tester) async { | ||
| final List<FlutterErrorDetails> errors = <FlutterErrorDetails>[]; | ||
| FlutterError.onError = (FlutterErrorDetails error) => errors.add(error); |
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.
Adds a common debug method for checking that a viewport has bounded constraints. Provides a clean and clear error message everywhere that we check for this. There was already an excellent check and error message written for this in computeDryLayout, so I moved it to be shared.
Fixes #78796
I did not make this debug method part of the viewport class because it can be used in the 2D viewport as well later. :)
Pre-launch Checklist
///).If you need help, consider asking for advice on the #hackers-new channel on Discord.