Setting up iOS Testing
- Getting Started
Setting up iOS Testing
In this section we will learn how to install and configure the necessary resources to start testing iOS applications in suittest.
iOS Testing can be achieved in 2 ways:
- Remote Mode: Connects to a Remote Farm
- NOTE: both Local Mode and Remote Mode use the same base engine, so scripts should be compatible in each mode
- Local Mode: requires Appium (See iOS Installation -> Appium)
Remote Device
Included Remote Farm support:
- BrowserStack
- SauceLabs
To use a Remote Device
- Create a device in Test Resources -> Mobile Devices
- Associate Farm accounts in the User Account page
- Device Farm accounts are connect at User level (each user can have a device farm account)
- To set the iOS App as available for Remote Farm, select 'Remote' in the Engine field, this will indicate that the application is intended for Remote Farms
Extra Configurations:
- IPA/ZIP Path: the machine path to the IPA/ZIP to be installed (in case of remote, it can be the File URL that the remote farm provides after uploading the app)
- If the test is run on a simulator, a ZIP is required, if it's a device, it's the IPA
- Device: the device to interact with
- Local: the Device ID, this field is optional, if left blank, it will use the available connected device/simulator
- Remote: the Remote device created in Remote Devices page, right clicking the field will display all the iOS devices available
- Host: the IP and Host of the Appium Server on Local Engine mode
- This field is optional, if left blank, it will use the localhost in the machine
- This field is optional
- Start as Webview: Apps may a NATIVE and WEB context, setting this field will "force" the app to launch in WEB mode (if the app supoprts it)
Local Mode
Pre requisites for setting up Local Mode
- minimum macOS: 14.1
- minimum Xcode: 15.0.1
Setting up Appium:
- Run the following Command: npm i --location=global appium
- Install the Appium Driver with the command: appium driver install xcuitest
- Starting the server (will be required each time you intend to automate a test) by running the command: appium
- in the command line, the available servers should be visible, both the localhost and the public. these can be used in the Host field in Test Resources->Appication->Host
NOTE: for Local Mode, when a real device is used, it must be in developer mode