Skip to content
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

Reland "[null-safety] reland: migrate app side flutter driver to null-safety" #67570

Merged

Conversation

jonahwilliams
Copy link
Member

@jonahwilliams jonahwilliams commented Oct 7, 2020

Reverts #67561

Fixes insertion of null string into message data which crashed integration with web driver. Adds unit test to cover

Fixes #67560

@flutter-dashboard flutter-dashboard bot added a: accessibility Accessibility, e.g. VoiceOver or TalkBack. (aka a11y) a: tests "flutter test", flutter_test, or one of our tests framework flutter/packages/flutter repository. See also f: labels. team Infra upgrades, team productivity, code health, technical debt. See also team: labels. labels Oct 7, 2020
@google-cla google-cla bot added the cla: yes label Oct 7, 2020
@goderbauer goderbauer changed the title Revert "Revert "[null-safety] reland: migrate app side flutter driver to null-safety"" Reland "[null-safety] reland: migrate app side flutter driver to null-safety" Oct 8, 2020
@@ -26,7 +26,8 @@ class RequestData extends Command {

@override
Map<String, String> serialize() => super.serialize()..addAll(<String, String>{
'message': message,
if (message != null)
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is the fix

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ahhh, OK, I was misunderstanding the ! because I wasn't seeing the != null around it; it's used to remove the ? from the type of the variable. Cool beans!

import '../../common.dart';

void main() {
test('RequestData does not insert "null" string when no message is provided', () {
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unit test for this

Copy link
Member

@ditman ditman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Manually tested this on my local repro of #67560, it seems to do the trick!!

Copy link
Member

@goderbauer goderbauer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
a: accessibility Accessibility, e.g. VoiceOver or TalkBack. (aka a11y) a: tests "flutter test", flutter_test, or one of our tests framework flutter/packages/flutter repository. See also f: labels. team Infra upgrades, team productivity, code health, technical debt. See also team: labels.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Flutter driver appears to be broken on web
4 participants