【发布时间】:2018-04-29 18:46:19
【问题描述】:
我正在使用 AppiumLibrary 和 Robotframwork 并遇到错误 FAIL : ValueError: Element locator '//*[@text="STG"]' did not match any elements。
Test Case1
| FAIL |
ValueError: Element locator '//*[@text="STG"]' did not match any elements.
这是测试用例:
**Settings**: Library AppiumLibrary
**Test Cases**: Test Case1
Open Application http://localhost:4723/wd/hub
platformName=Android deviceName=ZY22452GQX
app=/home/keval/Desktop/extra/app-rheem-qa(1).apk
appPackage=com.rheem.econetconsumerandroid.qa
appActivity=com.econet.ui.MainActivity
Click Element id=com.rheem.econetconsumerandroid.qa:id/
activity_login_logo_image_view
Click Element id=com.rheem.econetconsumerandroid.qa:id/
activity_login_logo_image_view
Click Element id=com.rheem.econetconsumerandroid.qa:id/
activity_login_logo_image_view
Click Text text=STG exact_match=False
Click Element id=com.rheem.econetconsumerandroid.qa:id/menu_save
Input Text id=com.rheem.econetconsumerandroid.qa:id/
login_email_text text=deepali.gill@volansystech.com
Input Password id=com.rheem.econetconsumerandroid.qa:id/
login_password_text text=kalpesh@2017
Click Element id=com.rheem.econetconsumerandroid.qa:id/login_button
【问题讨论】:
-
这不是问题。
-
您似乎没有在等待屏幕完成渲染。如果在导致错误的行之前添加等待或睡眠,错误会消失吗?
标签: automation appium robotframework appium-android