When I clicked Green Run button without explicitly specifying which browser to use*, I got the following error in the log view:
05-07-2019 03:26:02 ĺĺž Test Cases/QMW/visitSite
Elapsed time: 0.705s
Test Cases/QMW/visitSite FAILED.
Reason:
com.kms.katalon.core.exception.StepFailedException: Unable to open browser with url: ''
at com.kms.katalon.core.webui.keyword.internal.WebUIKeywordMain.stepFailed(WebUIKeywordMain.groovy:64)
at com.kms.katalon.core.webui.keyword.internal.WebUIKeywordMain.runKeyword(WebUIKeywordMain.groovy:26)
at com.kms.katalon.core.webui.keyword.builtin.OpenBrowserKeyword.openBrowser(OpenBrowserKeyword.groovy:81)
at com.kms.katalon.core.webui.keyword.builtin.OpenBrowserKeyword.execute(OpenBrowserKeyword.groovy:67)
at com.kms.katalon.core.keyword.internal.KeywordExecutor.executeKeywordForPlatform(KeywordExecutor.groovy:56)
at com.kms.katalon.core.webui.keyword.WebUiBuiltInKeywords.openBrowser(WebUiBuiltInKeywords.groovy:60)
at com.kms.katalon.core.webui.keyword.WebUiBuiltInKeywords$openBrowser.call(Unknown Source)
at visitSite.run(visitSite:6)
at com.kms.katalon.core.main.ScriptEngine.run(ScriptEngine.java:194)
at com.kms.katalon.core.main.ScriptEngine.runScriptAsRawText(ScriptEngine.java:119)
at com.kms.katalon.core.main.TestCaseExecutor.runScript(TestCaseExecutor.java:336)
at com.kms.katalon.core.main.TestCaseExecutor.doExecute(TestCaseExecutor.java:327)
at com.kms.katalon.core.main.TestCaseExecutor.processExecutionPhase(TestCaseExecutor.java:306)
at com.kms.katalon.core.main.TestCaseExecutor.accessMainPhase(TestCaseExecutor.java:298)
at com.kms.katalon.core.main.TestCaseExecutor.execute(TestCaseExecutor.java:232)
at com.kms.katalon.core.main.TestCaseMain.runTestCase(TestCaseMain.java:114)
at com.kms.katalon.core.main.TestCaseMain.runTestCase(TestCaseMain.java:105)
at com.kms.katalon.core.main.TestCaseMain$runTestCase$0.call(Unknown Source)
at TempTestCase1557210360662.run(TempTestCase1557210360662.groovy:21)
Caused by: com.kms.katalon.core.exception.StepFailedException: No driver is set for execution.
at com.kms.katalon.core.webui.driver.DriverFactory.startNewBrowser(DriverFactory.java:213)
at com.kms.katalon.core.webui.driver.DriverFactory.openWebDriver(DriverFactory.java:188)
at com.kms.katalon.core.webui.keyword.builtin.OpenBrowserKeyword$_openBrowser_closure1.doCall(OpenBrowserKeyword.groovy:74)
at com.kms.katalon.core.webui.keyword.builtin.OpenBrowserKeyword$_openBrowser_closure1.call(OpenBrowserKeyword.groovy)
at com.kms.katalon.core.webui.keyword.internal.WebUIKeywordMain.runKeyword(WebUIKeywordMain.groovy:20)
at com.kms.katalon.core.webui.keyword.builtin.OpenBrowserKeyword.openBrowser(OpenBrowserKeyword.groovy:81)
at com.kms.katalon.core.webui.keyword.builtin.OpenBrowserKeyword.execute(OpenBrowserKeyword.groovy:67)
at com.kms.katalon.core.keyword.internal.KeywordExecutor.executeKeywordForPlatform(KeywordExecutor.groovy:56)
at com.kms.katalon.core.webui.keyword.WebUiBuiltInKeywords.openBrowser(WebUiBuiltInKeywords.groovy:60)
at com.kms.katalon.core.webui.keyword.WebUiBuiltInKeywords$openBrowser.call(Unknown Source)
at Script1557193179393.run(Script1557193179393.groovy:6)
... 11 more
I checked the Project Setting > Execution and found the default driver was set âWeb Serviceâ
I know how to workaround the âUnable to open browser with urlâ message. Either of the following 2
When I run the test case, I should be careful enough to explicity choose which browser to use (firefox, chorme , ie âŚ).
Change the Project Setting > Execution ? Default execution to some browser, rather than âWeb Serviceâ.
Disucssion
The message Unable to open browser with url and No dirver is set for execution does not tell users who are new to Katalon Studio whatâs wrong; what they should do.
Itâs because your project in a WebService project.
If you want to change your project type to default project. Please open .prj file and change the value of <type> section from WEBSERVICE to GENERIC or WEBUI.
What do you mean by saying âItâs because âŚâ?
Please see my first image. When you create a project, there are radio buttons to help user specify their type of project.
If the project is a WebService project, the default execution should be WebService. UI and other features of Katalon Studio will support users to do their test API.
If the project is a Generic or WebUI project, the default execution should be Chrome.
I edited .prj file to be WEBSERVCE to GENERIC. and I restarted Katalon Studio, opened the project. ---- then there seems to be no change.
Please change to another browser. The WebService execution was saved then you need to change it.
OK, I was not careful enough which type of project to choose when I newly create a project. Thatâs all.
To those who encountered Unable to open browser with url , No driver is set for execution message, check which type of project you chose. If you are doing WebUI testing, you should change Project > Execution > Default execution to Chrome or firefox, rather than Web Service.
Itâs maybe the reason why so many users report the same issue here. We will consider to bring Generic project as default and a function to convert their project type.
Even in a âWeb UIâ type project, I can call WS.* keywords. This fact makes me think I do not have be mindful about the type of project (Web Service, Web UI, Mobile, Generic) at all.
I do not want a UI to change the type of Project. Rather, I want to forget about it. Itâs OK that Katalon Studio have the project type and use it internally. Katalon could hide it behind the scene.
Going back to the initial post, all I want you to do is make the error message more informative so that user can realize that he should do either of
When clicking the run button, he should explicitly specify the browser type, or
change the Project > Exection > Default execution to be his favorite browser type.
I am saying this, because I expect many new Katalon users in my organization in future would be confused.
@kazurayam
as far as i know (been a while since i played with katalon) the only benefit of choosing webservice template is that is changing the gui view (adding the quick controls for creating api request objects when using webservice) and changing the default execution for a new project.
for me that was fine, since my projects are mostly backend testing, so i dont have to remember to set the executor to âno browserâ when running them from CI (there is no point to use chrome, even headless, or any other driver, when doing just api/db testing)
for the rest, it doesnt matter what template you choose, you can use webUI keywords with webservice template and opposite, as you already find out.
is just a matter of what you will do most, UI or backend ⌠i think this is the logic behind the templates behavior.
I am trying to solve by applying the advice of this forum and it is impossible.
The error shown is:
Test Cases / Login Record Play FAILED.
Reason:
com.kms.katalon.core.exception.StepFailedException: Unable to open browser with url: ââ
at com.kms.katalon.core.webui.keyword.internal.WebUIKeywordMain.stepFailed (WebUIKeywordMain.groovy: 64)
What can be done?
I have updated Chromdriver, the chrome version, updated katalon, starting katalon as administrator.
I donât know what to do anymore. Solution?