vendredi 31 janvier 2020

Appium testcases on real devices won't recognize the elements they are supposed to click on

I wrote some tests for a react native app, provided here and there some testIDs (was working with testProps, so fine for Android and iOS) and tests were running smoothly on virtual devices (iOS Simulator and Android emulator). Now I have build an apk file and ipa from the react native app and if I want to run the appium tests on a real device with the (until now) perfectly working appium tests, the test doesn't seem to find the accessibility labels. I also inspected the pages with the appium inspector, but it doesn't seem to find the provided accessibility labels in the apk file. The logs aren't helpful either since it's just saying :

    [MJSONWP (b824eb6b)] Calling AppiumDriver.findElements() with args:
    ["accessibilityid","nextbutton.button","b824eb6b-2100-4e76-bf55-4c1fc341555a"] 
    [BaseDriver] Valid locator strategies for this request: xpath, id, class name, 
    accessibility id, -android uiautomator [BaseDriver] Waiting up to 0 ms for condition [WD 
    Proxy] Matched '/elements' to command name 'findElements' [WD Proxy] Proxying [POST 
    /elements] to [POST http://localhost:8200/wd/hub/session/c4a35d0d-d5be-4849-
    a3fc-13364f4fc77c/elements] with body: {"strategy":"accessibility 
    id","selector":"nextbutton.button","context":"","multiple":true} [WD Proxy] Got response 
    with status 200: {"sessionId":"c4a35d0d-d5be-4849-a3fc-13364f4fc77c","value":[]} [MJSONWP
    (b824eb6b)] Responding to client with driver.findElements() result: [] [HTTP] <-- POST 
    /wd/hub/session/b824eb6b-2100-4e76-bf55-4c1fc341555a/elements 200 102 ms - 74 [HTTP] 
    [HTTP] --> POST /wd/hub/session/b824eb6b-2100-4e76-bf55-4c1fc341555a/elements [HTTP] 
    {"using":"accessibility id","value":"nextbutton.button"}

Environment

Appium version: 1.15.1
Desktop OS/version used to run Appium: MacOS Catalina
Real device or emulator/simulator: Android 7, Galaxy S6 edge
#

Anyone else experienced this issue?

Aucun commentaire:

Enregistrer un commentaire