Get your setup working faster. Join our Discord for optimisation tips from elite testers.Join our Discord
Appium with Cucumber
Test your native and hybrid apps on a real device cloud. This guide helps you run your first Cucumber test build on a real Android or iOS device on BrowserStack.
This section covers running your first build with BrowserStack’s sample repo. To run builds with your existing test suite(s), skip to integrate your test suite.
Onboard faster with Test Companion
Launch in your IDE. Chat with the AI assistant to configure and run your first build instantly.
Launch in IDE
Opening Test Companion in your IDE
Prerequisites
BrowserStack Username and Access key. You can find this in your account profile. If you do not have an account yet, please sign up for a Free Trial.
Cucumber v2+, Java v8+.
If you are using Eclipse or IntelliJ IDEA for running tests, install the corresponding JUnit plugin.
If you are using CLI for running tests, ensure that Maven is installed on your machine, Maven environment variables are set, and Maven bin is added to system path, $PATH.
Run a sample build
Run a sample Cucumber test build, which is based on the JUnit runner, using your preferred method on BrowserStack:
After downloading the sample project, unzip it in the desired location.
Import the downloaded project
Click File → Import. Expand General, select Projects from Folder or Archive, and click Next. Then, navigate to the earlier unzipped downloaded project .
Configure your browserstack.yml config file
The browserstack.yml file holds all the required capabilities to run your tests on BrowserStack
Set access credentials
Set userName and accessKey properties in the browserstack.yml file, available in the root directory, to authenticate your tests on BrowserStack.
Select Android or iOS devices from a list of 150+ available combinations:
Use one of our sample apps to run your first Appium test on BrowserStack App Automate. Choose from the options below:
Platform
Select an OS to choose the devices from below
Android
Android
iOS
Parallel thread
#1
Windows 10
Chrome 120
Parallel thread
#2
OS X Monterey
Safari 15.6
Parallel thread
#3
iOS 15
iPhone 13
Update the browserstack.yml config file
Copy and replace the platforms object in the browserstack.yml file.