AppiumāāāArticle #1
š±Invoke an App in Mobile ā Appium
Learn Desired Capabilities to invoke the app in mobile
In this article, weāre going to learn about appium desired capabilities to invoke the app on the mobile. So Letās get started š
Prerequisites:
- Create a project and class in eclipse that I have taught in one of my articles, I recommend you to go through that article first.
2. Download and install the āApiDemos-debug.apkā app on which we will run our test case.
3. Copy and paste the āApiDemos-debug.apkā in the src folder to access the file.
Letās Do Coding š»
- After creating the class, you need to create an object (caps) of desired capabilities class and import it into the class like this š
2. Now, give the information to automate the test on the device so for this we use setCapabilities š
3. Here are some information that is required to invoke an app in your mobile.
Copy and paste the āApiDemos-debug.apkā in the src folder to access the file
Explain The Code
ā Desired Capabilities
Desired Capabilities is a class uses to set basic requirements, we basically wrap all the requirements in desired capabilitiesā object and send this information to the actual driver.
ā File
We used the File class to access the ā.apkā file from the src folder.
ā UiAutomator2
UiAutomator is introduced by Google who invented Android. Itās a testing framework that is used for automating android apps. So, we don't directly test our apps on mobile we use a mediator i.e. āUiAutomator2ā.
Appium cloned this UiAutomator framework repository and made some customized changes and give a name to it as āUiAutomator2ā. So to test the app on mobile weāre using āUiAutomator2ā.
ā AndroidDriver
This driver is a part of Appium Mobile Test Automation tool that controls all the automation.
Code To Use
Follow all the articles to learn Appium from scratch.
If you find this post useful, please tap š button below š
Best of Luck š