Hello Appium team,
I’m facing a persistent issue with the iOS simulator when automating a native app using Appium.
Here are the details:
- Appium version: 2.19.0
- XCUITest driver: 9.9.2
- WDIO version: 9.5.3
- Platform: iOS 18.2
- Device: iPhone 15 Pro simulator
- Automation framework: WebdriverIO
- App type: Native app
- Locator strategy: Accessibility ID
Problem:
The click()
method finds the element successfully (confirmed by logs), but the UI does not respond to the click consistently. Sometimes the button reacts, other times it silently fails, even though the element is clearly found and visible.
Logs confirm the element is located:
INFO webdriver: DATA { using: 'accessibility id', value: 'button-graphics' }
INFO webdriver: RESULT { ELEMENT: 'EB000000-...' }
INFO webdriver: COMMAND elementClick("EB000000-...")
INFO webdriver: RESULT null
No error is thrown, the click appears to be executed, but nothing changes in the UI.
What I’ve tried:
- Added
browser.pause()
before and after the click — no improvement
- Used
tap()
and coordinate-based tapping — same result
- Confirmed the issue only happens on the simulator, not on real devices
- The element is visible and interactable manually in the simulator
- Retrying the test may result in it working the next time — inconsistent behavior
Any help, ideas, or workarounds would be greatly appreciated.
Thank you!
Hi, please add capabilities and settings how you start driver. Possibly give ideas.
Nice problem description! With full info.
Did you try mobile methods -Execute Methods - Appium XCUITest Driver ?
Hey @Aleksei thank you for reply.
I’ve tried this as well, but unfortunately, it didn’t help.
The most frustrating part is that everything works fine at first — I log in (enter email, password, and click the [Log in] button), the loading happens, and the UI transitions as expected. But once the canvas is displayed and we need to click a button, things become very random: sometimes the click works and the test passes, but other times the screen freezes and I can’t even click manually using the touchpad.
// Key capabilities from your setup
capabilities: [{
platformName: ‘iOS’,
‘appium:automationName’: ‘XCUITest’,
‘appium:deviceName’: ‘iPhone 15 Pro’,
‘appium:platformVersion’: ‘18.2’,
‘appium:app’: ‘./apps/ios/Test.app’,
‘appium:udid’: ‘178CF31A-9F57-4042-9C1E-24DE7538CE00’,
‘appium:wdaLocalPort’: 8100,
‘appium:newCommandTimeout’: 240,
}]
Command:
“ios:local-simulator”: “npm run clean:results && npx wdio run config/local/wdio.ios.local.conf.ts --mochaOpts.grep=${TAG_IOS}”,
maybe it is pure app problem?
I don’t think so. On a real device, it runs without any problem
sec - when you trying manually:
- on real device you saying NO issues
- on simulator ARE issues “I can’t even click manually using the touchpad.”
a bit contradiction …
When I run tests on the simulator, the login process always works successfully. However, once the Canvas is loaded and a click on a specific button is supposed to happen, the click doesn’t go through.
When I run the same flow on a real device, both the login and the click actions always work perfectly.
So it seems like something is going wrong specifically on the simulator — maybe it gets stuck or something crashes right after login. But since the login itself works every time, it feels like the issue starts only after that…
How about when you run manually on simulator? Do you have issues when canvas appears?
For crash you can check logs with developer help.