This project serves as a boilerplate for automating both Android and iOS mobile applications using a single codebase with TestNG and the Appium library.
- Java
- Maven
- NodeJS
-
Install XCode
-
Download and Install Android Studio
-
Create a new system variable for
ANDROID_HOME
pointed to the Android SDK location -
Update the system path variable with
ANDROID_HOME\platform-tools
-
Install Appium 2.0
npm i -g appium@next
-
Install Appium Drivers
appium driver install uiautomator2
appium driver install xcuitest
Note: Environment Variables
-
Using IntelliJ IDEA
- Go to Maven Profiles
- Select
android
orios
Maven Profile as the platform - Select
dev
,qa
,uat
,pre-prod
orprod
as the environment - Select the test classes on the
src/test/java
folder - Right-click and click on
Run
-
Using Command Line
-
To run Android tests in QA environment
mvn clean test -Pandroid,qa
-
To run iOS tests in UAT environment
mvn clean test -Pios,uat
-
Note: By default, if no Maven profiles are selected, the tests will be executed on the android
platform and in the dev
environment.
Copyright 2023 MaxSoft.