Katalon Selenium Grid Example

This Katalon selenium grid example uses a Gridlastic selenium grid for browser execution. The selenium grid hub endpoint, credentials and video url are displayed after launching your Gridlastic selenium grid.

Gridlastic Katalon Setup

Step 1 : Go to Project->Settings

Step 2 : In project settings window expand the Desired Capabilities and select remote

Step 3 : In remote server url section provide your Gridlastic hub url and desired capabilities like:

Example Windows 10 Chrome with video recording enabled

Example Linux Chrome with specific version and no video recording enabled

Example Windows 10 Microsoft Edge with video recording enabled

Example Windows 10 Firefox specific version

Also required to specify firefox binary location "C:\Program Files (x86)\Mozilla Firefox\firefox82\firefox.exe" on the Gridlastic node.

Example Linux Firefox specific version

Also required to specify firefox binary location "/home/ubuntu/Downloads/firefox82/firefox" on the Gridlastic node.

Note: Starting with Chrome 77, when testing on windows you must include the capability "platformName" set to value "windows" otherwise the Chrome driver will not accept the request. In addition, you must also include the capability "platform" set to the standard values "VISTA", "WIN8", "WIN8_1" or "WIN10", in order to route your tests to the desired windows environment.

Step 4: If you enabled Gridlastic video recording (disabled by default), add this code to build and output the video url in your test cases:

import org.openqa.selenium.support.events.EventFiringWebDriver as EventFiringWebDriver
import org.openqa.selenium.remote.RemoteWebDriver as RemoteWebDriver
import org.openqa.selenium.remote.SessionId as SessionId
import com.kms.katalon.core.webui.driver.DriverFactory as DriverFactory

def driver = DriverFactory.getWebDriver()
SessionId sessionId = ((((driver) as EventFiringWebDriver).getWrappedDriver()) as RemoteWebDriver).getSessionId()
WebUI.comment('VIDEO URL: https://s3-us-west-1.amazonaws.com/027a15f2-530d-31e5-f8cc-7ceaf6355377/299a51a7-c526-cyb8-8fpd-1789b662a464/play.html?' + sessionId)

Step 5 : Once the above steps are completed execute your test in remote by selecting run->remote

Tip: to run your tests in parallel organize your tests in Test Suite Collections and take advantage of Gridlastic parallel execution capability.