Welcome to the Appium mobile automation testing guide using Webdriver.io and Node.js. This readme provides a step-by-step guide to set up and execute mobile tests using the powerful combination of Appium, Webdriver.io and Node.js.
Before you can start with the mobile automation testing using Appium, make sure you have the following prerequisites set up on your system:
- Node.js: install Node.js, which includes npm (Node Package Manager), from the official website: https://nodejs.org. Make sure you have a version of Node.js intalled that supports the features required by Webdriver.io and Appium.
- Appium: Install Appium globally on your system using the following command:
npm install -g appium
- AndroidSDK: Install the Android SDK and configure the necessary environment variables for Android mobile testing. Refer to the official Andoird documentation for installation instructions: https://developer.android.com/studio.
- Java Development Kit (JDK): Install the Java Development Kit (JD) on your system. Make sure you have the necessary Java environment variables set up.
- Appium Server: Start the Appium server on your local machine or on a remote machine. Make sure the Appium server is running before executing the tests.
- Android Device or Emulator: Connect a physical Android device or set up an Android emulator for testing. Ensure that the device or emulator is properly configured and accessible by Appium.
- Webdriver.io and Dependencies: Install the necessary dependencies for Webdriver.io by running the followig command in your project directory.
npm install
To get started with mobile automation testing, follow the steps below:
Clone the repository and install the dependencies by running the following commands:
git clone https://github.com/alphabin1/demo-appium-nodejs.git
cd demo-appium-nodejs
npm install
To execute the mobile tests, follow these steps:
- Enter the desired capabilities, such as
deviceName
andplatformVersion
, in thewdio.androidApp.js
file located atconfig/wdio.androidApp.js
. Modify these capabilities according to your target device. - Open your terminal or command prompt.
- Run the following command to execute the tests:
This command triggers the execution of the mobile tests on your terminal. Make sure you have the necessary devices connected and configured for Appium testing.
npm run androidApp
Feel free to explore and enhance the Appium mobile automation testing framework using Webdriver.io and Node.js to suit your specific mobile testing needs. Happy testing! 😊