mobile-dev-inc / maestro

Painless Mobile UI Automation
https://maestro.mobile.dev/
Apache License 2.0
5.42k stars 250 forks source link

Support unicode input #146

Open dmitry-zaitsev opened 1 year ago

dmitry-zaitsev commented 1 year ago

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

- inputText: Wünderbar
dmitry-zaitsev commented 1 year ago

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 commented 1 year ago

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:

mmeven commented 1 year ago

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 commented 1 year ago

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 commented 1 year ago

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 commented 1 year ago

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

dragonfire1119 commented 1 year ago

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 commented 1 year ago

Hi, When will Unicode be supported on Android? Is it already in the plans?

Thanks.

ChristianSteffensen commented 1 year ago

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

dragonfire1119 commented 1 year ago

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 commented 7 months ago

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

aliaamonier commented 6 months ago

Team , is there any update for the "Unicode character" for Android. This will help alot.

ignatovSA commented 6 months ago
  • 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 commented 3 months ago

Any updates for Android? @dmitry-zaitsev