Hi Folks, Hope this information helps.
After lot of struggle, finally resolved the issue. Below are the details
Hub Machine Configurations:
- Place selenium-server-standalone-3.0.1.jar file under katalon.exe file location.
2. Open command prompt from the same location and execute hub command
Command: java -jar selenium-server-standalone-3.0.1.jar -role hub
Node Machine Configurations:
1. Place selenium-server-standalone-3.0.1.jar and chromedriver.exe files under C drive any folder(i.e. C:\SeleniumGrid) location
2. Open command prompt from the same location and execute below command
Command: java -Dwebdriver.chrome.driver=C:\SeleniumGrid/chromedriver.exe -jar selenium-server-standalone-3.0.1.jar -role node -hub http://hubmachineipaddress:4444/grid/register
Note: Please provide your hub machine ip address
Hub Machine Configurations and Script run:
1. Open any browser and access console url(http://localhost:4444/grid/console) for seeing node register
2. Katalon Studio Script
Code:
import static com.kms.katalon.core.checkpoint.CheckpointFactory.findCheckpoint
import static com.kms.katalon.core.testcase.TestCaseFactory.findTestCase
import static com.kms.katalon.core.testdata.TestDataFactory.findTestData
import static com.kms.katalon.core.testobject.ObjectRepository.findTestObject
import com.kms.katalon.core.checkpoint.Checkpoint as Checkpoint
import com.kms.katalon.core.checkpoint.CheckpointFactory as CheckpointFactory
import com.kms.katalon.core.mobile.keyword.MobileBuiltInKeywords as MobileBuiltInKeywords
import com.kms.katalon.core.mobile.keyword.MobileBuiltInKeywords as Mobile
import com.kms.katalon.core.model.FailureHandling as FailureHandling
import com.kms.katalon.core.testcase.TestCase as TestCase
import com.kms.katalon.core.testcase.TestCaseFactory as TestCaseFactory
import com.kms.katalon.core.testdata.TestData as TestData
import com.kms.katalon.core.testdata.TestDataFactory as TestDataFactory
import com.kms.katalon.core.testobject.ObjectRepository as ObjectRepository
import com.kms.katalon.core.testobject.TestObject as TestObject
import com.kms.katalon.core.webservice.keyword.WSBuiltInKeywords as WSBuiltInKeywords
import com.kms.katalon.core.webservice.keyword.WSBuiltInKeywords as WS
import com.kms.katalon.core.webui.keyword.WebUiBuiltInKeywords as WebUiBuiltInKeywords
import com.kms.katalon.core.webui.keyword.WebUiBuiltInKeywords as WebUI
import internal.GlobalVariable as GlobalVariable
import org.openqa.selenium.Platform;
import org.openqa.selenium.WebDriver;
import org.openqa.selenium.remote.DesiredCapabilities;
import org.openqa.selenium.remote.RemoteWebDriver;
WebDriver driver = new RemoteWebDriver(new java.net.URL(“http://localhost:4444/wd/hub”), DesiredCapabilities.chrome());
driver.get(“http://www.google.com”);
Note: Please don’t give node machine ip address in the above URL, because, that didn’t work for me
3. Remote settings on katalon studio:
Navigation: Menu, Project --> Settings --> Execution --> Default --> Web UI --> Remote, Provide below details
Remote web server url : http://nodemachineipaddress:5555/wd/hub (It’s example data: 10.19.33.125 is the node machine ip address, 5555 is the hub registered node)
Remote web server type : Selenium
os : windows
Browser : Chrome
Click Apply and OK
- Click Run and select “Remote” option
Output:
You can see the execution on remote machine(i.e. node machine)