I am running Katalon on a Debian Linux system (Debian 4.17.17-1 (2018-08-18) x86_64). All my tests are failing, apparently because Katalon is unable to launch Chrome. I suspect that katalon doesn’t know where to find Chrome. Can anyone tell me how to configure this?
Here is the command I’m using to run Katalon.
/home/userx/katalon/katalon --args -noSplash -runMode=console -consoleLog -retry=0 -executionProfile="default" -browserType="Chrome (headless)" -projectPath="/home/userx/myproject/Tests/Tests.prj" -testSuitePath="Test Suites/List"
And here is an abbreviated version of the output I get:
Request sent successfully.
!SESSION 2018-09-18 17:34:25.242 -----------------------------------------------
eclipse.buildId=unknown
java.version=1.8.0_171
java.vendor=Oracle Corporation
BootLoader constants: OS=linux, ARCH=x86_64, WS=gtk, NL=en_US
Framework arguments: --args -runMode=console -retry=0 -executionProfile=default -browserType=Chrome (headless) -projectPath=/home/richard/as1mark/submissions/2-processing/As1Tests/As1Tests.prj -testSuitePath=Test Suites/List
Command-line arguments: -os linux -ws gtk -arch x86_64 -data config --args -runMode=console -consoleLog -retry=0 -executionProfile=default -browserType=Chrome (headless) -projectPath=/home/richard/as1mark/submissions/2-processing/As1Tests/As1Tests.prj -testSuitePath=Test Suites/List
!ENTRY org.eclipse.core.resources 2 10035 2018-09-18 17:34:28.854
!MESSAGE The workspace exited with unsaved changes in the previous session; refreshing workspace to recover changes.
Starting Groovy-Eclipse compiler resolver. Specified compiler level: unspecified
150 2.4.7.xx-201611170128-e46 = ACTIVE
--------------------------------------------------------------------------------
Test Suites/List - Chrome (headless) - 20180918_173432...................0/7(0%)
--------------------------------------------------------------------------------
Request sent successfully.
09-18-2018 05:34:35 PM - [START] - Start Test Suite : Test Suites/List
09-18-2018 05:34:35 PM - [RUN_DATA] - Logging run data 'hostName' with value 'userx - userx.redacted.com'
09-18-2018 05:34:35 PM - [RUN_DATA] - Logging run data 'os' with value 'Linux 64bit'
09-18-2018 05:34:35 PM - [RUN_DATA] - Logging run data 'hostAddress' with value '10.0.106.93'
09-18-2018 05:34:35 PM - [RUN_DATA] - Logging run data 'katalonVersion' with value '5.7.1.1'
09-18-2018 05:34:35 PM - [START] - Start Test Case : Test Cases/3.list-view/a-TotalRows
09-18-2018 05:34:35 PM - [INFO] - Evaluating variables for test case
09-18-2018 05:34:35 PM - [START] - Start setup action : setupTestCase
09-18-2018 05:34:36 PM - [START] - Start action : openBrowser
09-18-2018 05:34:36 PM - [END] - End action : openBrowser
09-18-2018 05:34:36 PM - [ERROR] - java.lang.ExceptionInInitializerError
09-18-2018 05:34:36 PM - [END] - End End action : setupTestCase
09-18-2018 05:34:36 PM - [ERROR] -
09-18-2018 05:34:36 PM - [END] - End Test Case : Test Cases/3.list-view/a-TotalRows
09-18-2018 05:34:36 PM - [START] - Start Test Case : Test Cases/3.list-view/b-AllFields
09-18-2018 05:34:36 PM - [INFO] - Evaluating variables for test case
09-18-2018 05:34:36 PM - [START] - Start setup action : setupTestCase
09-18-2018 05:34:36 PM - [START] - Start action : openBrowser
09-18-2018 05:34:36 PM - [END] - End action : openBrowser
09-18-2018 05:34:36 PM - [ERROR] - java.lang.NoClassDefFoundError: Could not initialize class com.kms.katalon.core.webui.keyword.builtin.OpenBrowserKeyword
09-18-2018 05:34:36 PM - [END] - End End action : setupTestCase
09-18-2018 05:34:36 PM - [ERROR] -
09-18-2018 05:34:36 PM - [END] - End Test Case : Test Cases/3.list-view/b-AllFields
[Removed lots of unhelpful lines here]--------------------------------------------------------------------------------
Test Suites/List - Chrome (headless) - 20180918_173432.................7/7(100%)
--------------------------------------------------------------------------------
You’ll notice two exceptions here. The first appears once, and the second is repeated for every test in the lines that I removed.
- 09-18-2018 05:34:36 PM - [ERROR] - java.lang.ExceptionInInitializerError
- 09-18-2018 05:34:36 PM - [ERROR] - java.lang.NoClassDefFoundError: Could not initialize class com.kms.katalon.core.webui.keyword.builtin.OpenBrowserKeyword
If you look at the test reports, you see these same exceptions.
Again, my suspicion is that katalon needs to be informed how to run chrome. I run chrome from “/usr/bin/google-chrome”. Is this what katalon expects? I should also say that I am running on a headless system. I’ve seen some posts recommending that I set a DISPLAY variable, and I’ve tried setting this variable to “:0.0” and “localhost:10.0” and similar values, but this doesn’t seem to make any difference.
Does anyone have any idea how to fix this?