vijay eathakotla
vijay eathakotla

Reputation: 11

Unable to add / send Text to a XCUIElementSecureTextField using Appium inspector

I'm using Appium Inspector to access the page source of an iOS App. I'm able to send Texts to XCUIElementTextField but not to the SecuretypeField. Even the keyboard is not showing up when I tried to click on the element.

note: I'm using the Sauce Labs device

Thanks :-)

Upvotes: 0

Views: 229

Answers (2)

breakingtesting
breakingtesting

Reputation: 21

You can apply another workaround instead of clicking "Show password" - send password not as a whole string, rather send its characters one by one. Below is example in Python:

for letter in password:
    field.send_keys(letter)
    time.sleep(.5)

Using 0.5 second sleep mimics users' behavior and works with Appium in my environment:

Upvotes: 0

Vicky
Vicky

Reputation: 1

You can click on the 'Show password' button and the XCUIElementSecureTextField will be changed to a simple XCUIElementTextField, enabling you to enter any text.

I also noticed some issues with sending characters to the XCUIElementSecureTextField and the only solution I found was to change the field type as I described above.

Upvotes: 0

Related Questions