-
Notifications
You must be signed in to change notification settings - Fork 6k
Send -1 for empty composition range #24865
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 Hixie on the #hackers channel in Chat. 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. |
|
I missed that we lost this conversation in the model unification PR. Could we get some unit tests set up for this so we don't regress it again? |
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.
Thanks for the fix! As Stuart says, a test would be fantastic here. Happy to help on that front.
|
@cbracken, any pointers as to what the test should look like is appreciated. |
|
https://github.com/flutter/engine/blob/7bc7fdb461734fff9fdf35179a00e692fb3d41fe/shell/platform/darwin/macos/framework/Source/FlutterViewControllerTest.mm has some tests that demonstrate validating calls made on a channel. You could make the text input plugin's |
|
@stuartmorgan, @cbracken, I added a test for this. Anything else or is this good to go? |
|
Thanks @knopp. Taking a quick look. Looks like it needs a quick rebase for |
cbracken
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 for adding the test.
shell/platform/darwin/macos/framework/Source/FlutterTextInputPluginTest.mm
Outdated
Show resolved
Hide resolved
f149425 to
4f0b1ed
Compare
|
I've kicked the build_and_test_linux presubmit. Re-run: https://cirrus-ci.com/task/6264967797145600 |
|
The test failure is a known flake. I've filed a report and re-run the test. |
flutter/flutter#77600
Pre-launch Checklist
writing and running engine tests.
///).If you need help, consider asking for advice on the #hackers-new channel on Discord.