Post

Replies

Boosts

Views

Activity

Reply to XCUITest - How do I type into a secure text field? (password)
The issue is related to the hardware keyboard: it should be disabled before launching UI tests. For this, add a new run script action in pre-actions for Test by editing your .xcscheme. The command line is: defaults write com.apple.iphonesimulator ConnectHardwareKeyboard 0 After your update, your .xcscheme must be: ... <TestAction ...> <PreActions> <ExecutionAction ActionType = "Xcode.IDEStandardExecutionActionsCore.ExecutionActionType.ShellScriptAction"> <ActionContent title = "Disable hardware keyboard (required to tap text when switching text fields)" scriptText = "defaults write com.apple.iphonesimulator ConnectHardwareKeyboard 0&#10;"> </ActionContent> </ExecutionAction> </PreActions> ... Note: it will be only effective after restarting your simulator.
Oct ’21