Execution CMD Mode in Bat file

When the bat file is executed, it returns error in the CMD

**Batch
**

katalon -noSplash  -runMode=console -consoleLog -projectPath="C:\Users\odp108603\Katalon Studio\API Gerar Protocolo\API Gerar Protocolo.prj" -retry=0 -testSuitePath="Test Suites/APIs" -executionProfile="default" -browserType="Chrome"

Error Exemple

!ENTRY com.kms.katalon.composer.testcase 4 0 2018-05-02 10:12:53.640
!MESSAGE FrameworkEvent ERROR!STACK 0org.osgi.framework.BundleException: Could not resolve module: com.kms.katalon.composer.testcase [1184]  Another singleton bundle selected: osgi.identity; type="osgi.bundle"; version:Version="1.0.0.201804270757"; osgi.identity="com.kms.katalon.composer.testcase"; singleton:="true"        at org.eclipse.osgi.container.Module.start(Module.java:444)        at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.dispatchEvent(ModuleContainer.java:1536)        at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.dispatchEvent(ModuleContainer.java:1)        at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230)        at org.eclipse.osgi.framework.eventmgr.EventManager$EventThread.run(EventManager.java:340)

I solved the problem.

Problem in path Katalon in CMD Execution.

Eduardo de Faria Grangeiro said:

I solved the problem.

Problem in path Katalon in CMD Execution.

Hey Eduardo - I’m running into the same problem recently. I have not moved/changed install of Katalon, however I am not getting this error. What exactly did you need to change in your cmd path? Thanks!

Micaela,

You can automatically generate a command for a batch file by clicking the “Build CMD” button to the left of the “Run” button on the top right of the screen, selecting a Test Suite, selecting a Browser and clicking the Generate Command button…

The batch file created for the command line will generally look like this (e.g. Project Name=Kuali), however, the change directory command is not included and must be supplied by you:

//Location where the Katalon.exe file is installed…

cd C:\Katalon Studio\Katalon_Studio_Windows_64-5.4.1

//The Project Path entry depends on where you save your Project (e.g. C:\Katalon Studio)…
//The Report Folder entry is located relative to your Project (e.g. C:\Katalon Studio\Kuali\)…
//The Test Suite Path entry is located relative to your Project (e.g. C:\Katalon Studio\Kuali\)…

katalon -runMode=console -projectPath=“C:\Katalon Studio\Kuali\Kuali.prj” -reportFolder=“Reports/Kuali” -reportFileName=“Kuali” -retry=0 -testSuitePath=“Test Suites/Kuali” -browserType=“Chrome”

Note: Remember to use forward slashes for the “-reportFolder=” and “-testSuitePath=” values, and back slashes for the “-projectPath=” value…

Additional Note: I added the -reportFolder="" and -reportFile="" entries as they are not included automatically…

Micaela Connors said:

Eduardo de Faria Grangeiro said:

I solved the problem.

Problem in path Katalon in CMD Execution.

Hey Eduardo - I’m running into the same problem recently. I have not moved/changed install of Katalon, however I am not getting this error. What exactly did you need to change in your cmd path? Thanks!

Hey Micaela,

Sorry late answer.

I’m used this code:

This is path the Katalon in my case C:\Katalon Studio

In CMD Script:

set dt=%date:~4,2%%date:~7,2%%date:~10,4%
cd\
cd "Katalon Studio"
katalon -runMode=console -consoleLog -noSplash -projectPath="C:\Users\odp108603\git\odontoprev_automacao\Portal Odontoprev.prj" -testSuitePath="Test Suites/AUTOMACAO - LOGIN" -executionProfile="default" -reportFolder="C:\Reports\Odontoprev\Login\%dt%" -reportFileName="odontoprev.html" -browserType="Chrome"