This repository demonstrates how to run Appium tests in JUnit4 and Junit5 on BrowserStack App Automate.
These code samples are currently based on:
- Appium-Java-Client:
8.1.1
- Protocol:
W3C
-
Java 8+
-
Maven
To install the dependencies for Android tests, run :
-
For Junit4
cd android/junit4-examples mvn clean
-
For Junit5
cd android/junit5-examples mvn clean
Or,
To install the dependencies for iOS tests, run :
-
For Junit4
cd ios/junit4-examples mvn clean
-
For Junit5
cd ios/junit5-examples mvn clean
Getting Started with Appium tests in Junit4 and Junit5 on BrowserStack couldn't be easier!
-
Junit4
- Update
first.conf.json
file inside thesrc/test/resources/com/browserstack/run_first_test
of Android Junit4 examples or iOS Junit5 examples with your BrowserStack Username and Access Key - Run
mvn test -P first
- Update
-
Junit5
- Update
first.conf.json
file inside thesrc/test/resources/com/browserstack/run_first_test
of Android Junit5 examples or iOS Junit5 examples with your BrowserStack Username and Access Key - Run
mvn test -P first
- Update
-
Junit4
- Update
parallel.conf.json
file inside thesrc/test/resources/com/browserstack/run_parallel_test
of Android Junit4 examples or iOS Junit5 examples with your BrowserStack Username and Access Key - Run
mvn test -P parallel
- Update
-
Junit5
- Update
parallel.conf.json
file inside thesrc/test/resources/com/browserstack/run_parallel_test
of Android Junit5 examples or iOS Junit5 examples with your BrowserStack Username and Access Key - Run
mvn test -P parallel
- Update
-
Junit4
- Update
local.conf.json
file inside thesrc/test/resources/com/browserstack/run_local_test
of Android Junit4 examples or iOS Junit5 examples with your BrowserStack Username and Access Key - Run
mvn test -P local
- Update
-
Junit5
- Update
local.conf.json
file inside thesrc/test/resources/com/browserstack/run_local_test
of Android Junit5 examples or iOS Junit5 examples with your BrowserStack Username and Access Key - Run
mvn test -P local
- Update
Note: If you are facing any issues, refer Getting Help section
For other Java frameworks samples, refer to following repositories :
Note: For other test frameworks supported by App-Automate refer our Developer documentation
If you are running into any issues or have any queries, please check Browserstack Support page or get in touch with us.