I am testing my React Native app using Appium and WebdriverIO. Having difficulty in changing slider values.
Normally in XCUITest I can easily achieve this using the following code:
app.sliders["slider-red"].adjust(toNormalizedSliderPosition: 0)
How to do the equivalent in Appium/WebdriverIO? I read somewhere that I should call sendKeys(). I tried the following:
$('~slider-red').sendKeys(['0']);
But it is giving me the following error:
invalid element state: Error Domain=com.facebook.WebDriverAgent Code=1 "The on-screen keyboard must be present to send keys"
It looks like sendKeys is for input fields, not for sliders!