Katalon Studio

Using Katalon Studio, a mobile tester can design automation tests for both Android and iOS apps on physical devices, cloud services or emulators.

This tutorial explains how to setup a mobile automation project and test a mobile app using Katalon Studio on Windows. This tutorial assumes that you are familiar with general principles of automated testing and have some experience with Katalon Studio IDE.

Unlike Web application testing, to test a mobile app, you need to install Node.js and Appium in addition to Katalon Studio.

Setting up Mobile Automation Project in MacOS

Install Node.js

Note: Make sure you install Node.js into a location where you have full Read and Write permissions.

  • When installing Node.js, make sure that the Add to PATH option is checked.

  • Verify if Node.js is installed correctly. Open Windows command line and type the command: where node to see if the system can find Node.js.

Install Appium

  • Open Command Prompt of Windows and input following command to install Appium:

npm install -g appium

  • Open Katalon Studio and go to the Windows > Katalon Studio Preferences > Katalon > Mobile settings. Set Appium Directory to the installed folder. By default, it’s usually installed at C:\Users\{your login account}\AppData\Roaming\npm\node_modules\appium.
  • You can also specify the level of log details to be displayed for Mobile execution using the Appium Log Level as well. There are two options: with Info, you can get the log at simple level while Debug is used in case you want more details logs.

Setup Devices

  • Install USB Driver for your phone, you can download it from the device manufacturer site. (If your Android phone is one of Google Nexus series, please skip this step because Android SDK already includes the driver)
  • Turn on the phone developer mode (go to Settings -> Developer options).
  • Connect your Android device to the computer using USB cable. Just confirm if prompted for accepting/trusting the phone.
  • Check whether the device is ready for automation by using ADB: Open command prompt, type command “adb devices” (without quotes). System should display a list of devices which have been connected. If this command is not recognized, then download and install the adb driver

Notes: Katalon Studio also supports mobile emulators. You can start emulators and launch your virtual devices. As long as they can be recognized by using the adb command, it should be fine to execute mobile tests with them.

Desired Capabilities

You can modify extra Desired Capabilities when executing automation test in Katalon Studio.

See also  Smarter, Faster, Better: The AI Revolution in Test Automation

To define Desired Capabilities for local execution using Chrome, Firefox, IE, Safari or Edge, please access Project > Settings > Execution > Default > Mobile > Android (iOS option is available in macOS)

The example below show a desired capabilities settings for Android to enable Unicode input.

Screen Shot 2017-07-13 at 14.55.09.png

Refer to https://github.com/SeleniumHQ/selenium/wiki/DesiredCapabilities for information on which properties of each web browser are supported by Selenium. For Desired Capabilities used with Appium, refer to http://appium.io/slate/en/master/?ruby#appium-server-capabilities.

External Library

With this setting, you can add or remove your external libraries from Project > Settings > External Libraries.

  • Add: Click to add your external libraries. The selected libraries will be copied to the Drivers folder in the Katalon project.
  • Remove: Click to remove existing libraries. They will be removed from the Drivers folder in the Katalon project.

The added libraries can be imported and utilized in the Script View of test cases:

Mobile Application

You need to save your mobile application (APK files for Android) to a location where your computer can access with full permission.

2 COMMENTS

LEAVE A REPLY

Please enter your comment!
Please enter your name here

This site uses Akismet to reduce spam. Learn how your comment data is processed.