DZone
Thanks for visiting DZone today,
Edit Profile
  • Manage Email Subscriptions
  • How to Post to DZone
  • Article Submission Guidelines
Sign Out View Profile
  • Post an Article
  • Manage My Drafts
Over 2 million developers have joined DZone.
Log In / Join
Refcards Trend Reports
Events Video Library
Refcards
Trend Reports

Events

View Events Video Library

Zones

Culture and Methodologies Agile Career Development Methodologies Team Management
Data Engineering AI/ML Big Data Data Databases IoT
Software Design and Architecture Cloud Architecture Containers Integration Microservices Performance Security
Coding Frameworks Java JavaScript Languages Tools
Testing, Deployment, and Maintenance Deployment DevOps and CI/CD Maintenance Monitoring and Observability Testing, Tools, and Frameworks
Culture and Methodologies
Agile Career Development Methodologies Team Management
Data Engineering
AI/ML Big Data Data Databases IoT
Software Design and Architecture
Cloud Architecture Containers Integration Microservices Performance Security
Coding
Frameworks Java JavaScript Languages Tools
Testing, Deployment, and Maintenance
Deployment DevOps and CI/CD Maintenance Monitoring and Observability Testing, Tools, and Frameworks

Last call! Secure your stack and shape the future! Help dev teams across the globe navigate their software supply chain security challenges.

Modernize your data layer. Learn how to design cloud-native database architectures to meet the evolving demands of AI and GenAI workloads.

Releasing software shouldn't be stressful or risky. Learn how to leverage progressive delivery techniques to ensure safer deployments.

Avoid machine learning mistakes and boost model performance! Discover key ML patterns, anti-patterns, data strategies, and more.

Related

  • Selenium vs Cypress: Does Cypress Replace Selenium?
  • Why We Still Struggle With Manual Test Execution in 2025
  • Refining Automated Testing: Balancing Speed and Reliability in Modern Test Suites
  • Munit: Parameterized Test Suite

Trending

  • Measuring the Impact of AI on Software Engineering Productivity
  • Immutable Secrets Management: A Zero-Trust Approach to Sensitive Data in Containers
  • Understanding IEEE 802.11(Wi-Fi) Encryption and Authentication: Write Your Own Custom Packet Sniffer
  • Cookies Revisited: A Networking Solution for Third-Party Cookies
  1. DZone
  2. Testing, Deployment, and Maintenance
  3. Testing, Tools, and Frameworks
  4. Executing Automated Tests in Console Mode in Katalon Studio

Executing Automated Tests in Console Mode in Katalon Studio

Learn how to execute automated test cases in the Katalon Studio testing framework in console mode, using the command prompt.

By 
Oliver Howard user avatar
Oliver Howard
·
Oct. 06, 17 · Tutorial
Likes (6)
Comment
Save
Tweet
Share
14.5K Views

Join the DZone community and get the full member experience.

Join For Free

One of the advantages of Katalon Studio is that you can execute automation tests without launching Katalon Studio IDE by using command line mode execution. Users use this function to run execution batch files or planning jobs in CI tools. This easy-to-follow guide will walk you through the steps of how to execute test cases using the command prompt.

Execute Katalon in CMD

1. Open the command prompt and navigate to the Katalon Studio folder that contains the katalon.exe file. For example:

open Katalon.exe

2. Enter the following syntax to execute automation tests:

katalon {option1} {option2} ... {optionN}

This command includes:

Item Description
katalon The command of Katalon Studio to execute automation test.
{option(s)} The additional options for the execution (see the description below for details).

For example:

C:

cd C:\Katalon\4.7

katalon -runMode=console -projectPath="C:\Project\Sample Project.prj" -reportFolder="Reports" -reportFileName="report" -retry=0 -testSuitePath="Test Suites/TS_RegressionTest" -browserType="Chrome"

3. Press Enter to start execution.

Katalon Command Line Options

Here’s the list of options supported in the “katalon” command:

Katalon Command Line Option Description Required?
-runMode=console Enable the console mode. Yes
-projectPath=<path> Specify the project folder that includes the.prj file. The absolute path must be used in this case. Yes
-testSuitePath=<path> Specify the test suite file (without extension.ts). The relative path (relative to the project folder) must be used in this case. Yes
-testSuiteCollectionPath=<path> Specify the test suite file (without extension.tsc). The relative path (relative to the project folder) must be used in this case.

Note: Available only from version 4.4 and later

Yes (If -testSuitePath is not used. Otherwise it’s optional)
-browserType=<browser> Specify the browser type used for test suite execution.

The following browsers are supported in Katalon:

  • Firefox
  • Chrome
  • IE
  • Safari
  • Remote
  • Android
  • iOS
Yes
-remoteWebDriverType=<Selenium, Appium> Remote web’s driver type (Selenium or Appium) Yes (If -remoteWebDriverUrl is used)
-deviceId=<device Id for Android/device uuid for ios> Specify the device’s ID to execute test scripts Y (If -browserType=Android or -browserType=iOS is used)
-consoleLog Display log in the console. No
-noExit Keep the console open after the execution is completed. No
-summaryReport Send summary report of a batch run. No
-statusDelay=<seconds> System will update the test case’s execution status after the specified seconds. No
-retry=<number of retry times> Number of times running test cases in the test suite. No
-retryFailedTestCases=<true, false> Retry failed test cases (overriding the setting in the test suite file). Set true if you want to rerun failed test cases and false otherwise. No
-qTestDestId=<destination’s id> Id of the destination where the result will be uploaded to No
-qTestDestType=<destination’s type> Type of the destination. There are 4 types, including “test-suite”, “test-cycle”, “release”, and “root”. No
-reportFolder=<path> Specify the destination folder to store report files. Can use an absolute path or relative path (relative to the project folder). No
-reportFileName=<name> Specify the name of report files (.html, .csv, .log). If not provided, the system uses the name “report” (report.html, report.csv, report.log). This option only takes effect when being used with “-reportFolder” option. No
-remoteWebDriverUrl=<remote web server url> Specify the remote web driver’s URL No
-email The email used to register Katalon Studio No (If Katalon Studio is already activated)
-password The corresponding password for the registered email above. No (If Katalon Studio is already activated)

Command Builder

Instead of typing directly in the command prompt, you can quickly generate commands to execute test suites by following the steps below:

1. Click on Build CMD from the main toolbar.
Build CMD Katalon Studio

2. The Generate Command for Console Mode dialog is displayed as below. Configure your options as needed.

Generate Command for Console Mode
This dialog has the following options:

Section Description
Test Suite The Test Suite or Test Suite Collection to be executed
Executed Platform

The platform used to execute the test:

Executed Platform Katalon Studio

Remote Web Driver URL is enabled if you choose to run with a Remote option.

Mobile Device is enabled if you choose to run with Android or iOS.

Custom Execution is enabled if you choose to run with Custom option.

Report Configuration

Extra settings for report after the execution is completed:

Extra settings for report

Output Location: the local folder to export the report.

Use relative path to current project: display the relative path to the output location, starting from the current project location.

Report File Name: the name for your generated report.

Send Summary Report to recipients below: enable sending the summary report to recipients who emails are specified Mail Recipients.

Other Options Other Report Options

3. Click on Generate Command after you complete the configuration. The command is generated and shown in a dialog, as below:
Generate Command Katalon Studio

4. You can Copy to Clipboard and paste it into the command prompt for execution.

Use Console.properties File

Instead of specifying command settings for each execution, you can place all settings in the console.properties and use this file in the command prompt. This file can be generated using the same Command Builder as above.

1. Generate console.properties file using Command Builder

Command Builder Katalon Studio
2. The console.properties file will be generated to your preferred location. You can open and update the parameters manually as needed.For example:
open and update the parameters manually

3. Run the console.properties file in the console mode using the following syntax:
katalon -propertiesFile="<absolute path to console.properties file>" -runMode=console

For example:

  • katalon -propertiesFile="D:\Katalon\Demo_Project\console.properties" -runMode=console

4. You can add extra Katalon command options to this command. Any option already defined in the console.properties file will be overwritten by the one declared on the command line.katalon -propertiesFile="<absolute path to console.properties file" -runMode=console -browserType=IE
This command runs the test on IE instead of Chrome as browserType is set to IE.

For more tutorials about Katalon Studio, please visit the Resources Center!

Testing Katalon Studio Console (video game CLI) Command (computing) Test suite Execution (computing)

Published at DZone with permission of Oliver Howard. See the original article here.

Opinions expressed by DZone contributors are their own.

Related

  • Selenium vs Cypress: Does Cypress Replace Selenium?
  • Why We Still Struggle With Manual Test Execution in 2025
  • Refining Automated Testing: Balancing Speed and Reliability in Modern Test Suites
  • Munit: Parameterized Test Suite

Partner Resources

×

Comments

The likes didn't load as expected. Please refresh the page and try again.

ABOUT US

  • About DZone
  • Support and feedback
  • Community research
  • Sitemap

ADVERTISE

  • Advertise with DZone

CONTRIBUTE ON DZONE

  • Article Submission Guidelines
  • Become a Contributor
  • Core Program
  • Visit the Writers' Zone

LEGAL

  • Terms of Service
  • Privacy Policy

CONTACT US

  • 3343 Perimeter Hill Drive
  • Suite 100
  • Nashville, TN 37211
  • support@dzone.com

Let's be friends: