[Mobile] Install WebDriverAgent for iOS devices
The WebDriverAgent is a WebDriver server used to control iOS devices remotely. It is automatically downloaded with Appium as appium-webdriveragent
.
- You have enrolled in the Apple Developer Program. To learn more about the Apple Developer Program enrollment, you can refer to this Apple document: Enrollment.
- Xcode installation. You can download it from the Apple developer website here: Xcode.
- Appium installation. To learn more about installing Appium, you can follow the steps in the Appium document here: Getting started.
In this article, we demonstrate how to install the WebDriverAgent via Katalon built-in tools and manual installation.
Install the WebDriverAgent with Katalon built-in tools
Install the WebDriverAgent manually
-
In Xcode > Preferences > Account, click Add (+) to enter your Apple Developer Account ID and password.
To navigate to the location of the WebDriverAgent, open Terminal, copy and paste the command line argument below:
cd /usr/local/lib/node_modules/appium/node_modules/appium-webdriveragent
For Appium version 1.14.2 or older, copy the following command instead:
cd /usr/local/lib/node_modules/appium/node_modules/appium-xcuitest-driver/webdriveragent
-
After going to the WebDriverAgent location, run the following command to initialize the WebDriverAgent project:
mkdir -p Resources/WebDriverAgent.bundle
Note:- For Appium version older than 1.20.0, you also need to run the following script on the same terminal:
sh ./Scripts/bootstrap.sh -d
Note:- Error code 13: re-run command with sudo:
sudo./Scripts/bootstrap.sh -d
-
Error _Error StackTrace: Cannot find module 'eslint-config-appium': _missing paramter
-d
when running/Scripts/bootstrap.sh
-
Open Finder and type appium-webdriveragent to quickly search for the folder. In the opened folder, double-click the WebDriverAgent.xcodeproj file to open it in Xcode.
-
After opening WebDriverAgent.xcodeproj file in Xcode, you need to build three targets:
-
The IntergrationApp target:
-
Select the IntergrationApp target. In the Signing & Capabilities section, check the Automatically manage signing box, then choose a team.
-
On the menu bar, select Product > Build.
-
-
The WebDriverAgentLib target:
-
Select the WebDriverAgentLib target. In the Signing & Capabilities section, check the Automatically manage signing box, then choose a team added in Step 1.
-
On the menu bar, select Product > Build.
-
-
The WebDriverAgentRunner target:
-
Select the WebDriverAgentRunner target. In the Signing & Capabilities section, check the Automatically manage signing box, then choose a team added in Step 1.
-
On the menu bar, select Product > Build.
-
-