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

Support unicode input #146

Open
dmitry-zaitsev opened this issue Sep 8, 2022 · 15 comments
Open

Support unicode input #146

dmitry-zaitsev opened this issue Sep 8, 2022 · 15 comments
Labels
enhancement New feature request or improvement of an existing feature platform: android Testing Android apps is affected

Comments

@dmitry-zaitsev
Copy link
Collaborator

At the moment Maestro does not allow to input unicode characters, so commands like this one won't work:

- inputText: Wünderbar
@dmitry-zaitsev dmitry-zaitsev added enhancement New feature request or improvement of an existing feature platform: ios Testing iOS apps is affected platform: android Testing Android apps is affected labels Sep 8, 2022
@dmitry-zaitsev
Copy link
Collaborator Author

On iOS, the issue is in the fact that idb inputs text by sending key events to the device, instead of passing the text as a whole.

@dmitry-zaitsev
Copy link
Collaborator Author

On Android, the issue is in the fact that adb shell input text {text} does not work with unicode.

We have tried to solve the problem in following ways:

  • Use UiAutomator directly. This allows for input of unicode, but adds a weird limitation - it is not possible to append text input to a field due to the fact that if a field has a hint, it will be counted as a text.
  • Use ADBKeyboard. While it looks promising, it also requires user to enable the keyboard in Android settings. We would like to keep Maestro configuration as simple as possible, so this is a no-go.

@mmeven
Copy link

mmeven commented Dec 13, 2022

Hi 👋
Any update on the subject ? The iOS issue makes it impossible to run tests when using any non-QWERTY keyboard layout.

Thank you for your time

@langtind
Copy link

langtind commented Dec 27, 2022

Related iOS issue: The input don't handle different keyboard layout. I do use QWERTY, but with Norwegian layout. See image, _ and ? are swapped

Text editor vs actual simulator input:
image

edit: By reading #107 I see that this is already mentioned by others.

@marnoux-luna
Copy link

Hi @dmitry-zaitsev,

Do you have any update on this issue? Or any workaround other that switching the mac keyboard to QWERTY?

Thanks 🙏

Martin

@dmitry-zaitsev dmitry-zaitsev removed the platform: ios Testing iOS apps is affected label Jan 30, 2023
@dmitry-zaitsev
Copy link
Collaborator Author

Unicode is now supported on iOS. Android is still work in progress

@dragonfire1119
Copy link

Unicode is now supported on iOS. Android is still work in progress

I have yet to get Maestro to type out a full email address. Are you sure it's fixed?

@openerserver

This comment was marked as spam.

@ChristianSteffensen
Copy link

I'm interested to know the status of this too. Is there a way to interact with the keyboard itself as a workaround?

@dragonfire1119
Copy link

I'm interested to know the status of this too. Is there a way to interact with the keyboard itself as a workaround?

I had to just go back to using https://wix.github.io/Detox/ :(

It skips letters when you type, which throws off the whole test.

@NehaKharbanda99
Copy link

i am interested to know the status of this also - unicode suppprt for android. struggling for this.

@aliaamonier

This comment was marked as spam.

@ignatovSA
Copy link

  • Use UiAutomator directly. This allows for input of unicode, but adds a weird limitation - it is not possible to append text input to a field due to the fact that if a field has a hint, it will be counted as a text.

Probably, this limitation is not as bad as complete absence of Unicode

Do you have any plans on supporting android unicode? Is it possible to move forward with UiAutomator option?

@art-ylem

This comment was marked as spam.

@Thelm76
Copy link

Thelm76 commented Nov 27, 2024

For future reference, here is the ADB issue :
https://issuetracker.google.com/issues/207386157

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature request or improvement of an existing feature platform: android Testing Android apps is affected
Projects
None yet
Development

No branches or pull requests