Settings

  • Library AppiumLibrary

Variables

${REMOTE_URL}   http://localhost:4723/wd/hub
${PLATFORM_NAME}    Android
${PLATFORM_VERSION}     10
${DEVICE_NAME}     868101048880709
${PACKAGE_NAME}     com.iremitx.light.remit
${ACTIVITY_NAME}    com.example.love.MainActivity

Keywords

Open test application
Open Application    ${REMOTE_URL}
platformName=${PLATFORM_NAME}
platformVersion=${PLATFORM_VERSION}
deviceName=${DEVICE_NAME} 
appPackage=${PACKAGE_NAME}
appActivity=${ACTIVITY_NAME}  

Login app test

Input Text  xpath://input[@id="0804146915"]
Input Text  xpath://input[@id="123123"]
Click Element  xpath://button[@type="Login]

Test Cases

  • TC01 Open test application for android Open test application

  • TC02 Login app Login app test

kindly suggest me web or book or channel on youtube for studing automate test.

enter image description here

1

There are 1 best solutions below

0
On

You should use Appium Inspector to find and get the element locator you need. The locators have a different structure than the ones in SeleniumLibrary.

Here is my example for an input element:

AppiumLibrary.Input Text    //android.view.View[@text='Email']/../android.widget.EditText[1]    ${username}