Preparing to run mobile Web UI tests using industry-standard browsers

Before you can run mobile Web UI tests using industry-standard browsers, you must set up the Appium environment. For Android, you must prepare the Android devices and emulators with the recommended Appium settings before running the Web UI tests. For iOS devices and simulators, you must also set up an iOS WebDriverAgent project.

Procedure

  1. Download, install, and set up Appium. Appium is an open source test automation framework that can drive Android and iOS apps using the Selenium WebDriver protocol. For iOS testing, be sure to prepare the Appium environment on an Apple Macintosh computer. Refer to the following articles and video for details.
  2. For iOS testing, set up an iOS WebDriverAgent project. This project is required to run applications on an iOS device. See the following links for additional details:

    Follow these steps to set up and open the WebDriverAgent project on an Apple Macintosh computer:

    1. Change directory to /Applications/Appium.app/Contents/Resources/app/node_modules/appium/node_modules/appium-xcuitest-driver/WebDriverAgent.
    2. Create a new directory by typing mkdir -p Resources/WebDriverAgent.bundle.
    3. Run the following script to create the WebDriverAgent project: ./Scripts/bootstrap.sh -d.
    4. Open the new WebDriverAgent project: in Xcode. While still in the newly created directory, type open and then double click WebDriverAgent.xcodeproj.
    5. When the project opens, sign all “TARGETS” by adding the name of your Apple dev team.
    6. While still in the WebDriverAgent directory, type /Applications/Appium.app/Contents/Resources/app/node_modules/appium/node_modules/appium-xcuitest-driver/WebDriverAgent.
    7. Build the WebDriverAgent project by typing xcodebuild -project WebDriverAgent.xcodeproj -scheme WebDriverAgentRunner -destination 'id=9449480190d03228251969fadd5ced40de2f5a41' test.
    8. Verify the build by looking for messages that indicate success:
      Test Suite 'All tests' started at 2018-06-25 22:41:23.837
      Test Suite 'WebDriverAgentRunner.xctest' started at 2018-06-25 22:41:23.838
      Test Suite 'UITestingUITests' started at 2018-06-25 22:41:23.838
      Test Case '-[UITestingUITests testRunner]' started.
      t =     0.00s Start Test at 2018-06-25 22:41:23.839
      t =     0.00s Set Up
Feedback