CMD execution: Unable to resolve class

## OS (Windows 10? OSX Sierra?): Windows 10

## Katalon Studio Version (4.7?, 5.4.0

## Katalon Studio logs:

Windows (\config\.metadata\.log): katalon.versionNumber=5.3.1

## Environment (for Web testing)

Browser (Internet Explorer 11? Firefox 52? Chrome 62?): ALL

## Steps to reproduce -

When running the TS over the command line, the test is terminated prematurely (The problem occurs not every time you start up:-/)

start /wait katalon -noSplash -runMode=console -consoleLog -noExit -projectPath=“C:\Bitbucket\JAT\automatic-tests\JAT.prj” -retry=0 -testSuitePath=“Test Suites/Import/ABOImportBase” -executionProfile=“AKCEPT” -browserType=“Firefox”

04-19-2018 10:43:43 -
[ERROR] - Cases / IB / Common / Initialization failed FAILED because
(of) org.codehaus.groovy.control.MultipleCompilationErrorsException:
startup failed:
file: / C:
24: unable to resolve class common.Combase
04-19-2018 10:43:43 - [END] - End Test Case: Test Cases / IB / Common / Initialization
@ line 24, column 1.
import common.Combase as Combase

1 error

TC Initialization
BEGIN SCRIPT -------------------------

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 org.junit.After

import com.kms.katalon.core.checkpoint.Checkpoint as Checkpoint
import com.kms.katalon.core.checkpoint.CheckpointFactory as CheckpointFactory
import as MobileBuiltInKeywords
import 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 common.Combase as Combase

‘Otevreni internetoveho prohlizece s IB linkem.’

‘Vypis nazvu testovaneho prostredi.’
switch (GlobalVariable.PageUrlIB) {
case ~(’(.)’) :
println(‘Test se spousti na predprodukcnim prostredi.’)

case ~('(.*)*)') :  
    println('Test se spousti na integracnim prostredi.')  

case ~('(.*)*)') :  
    println('Test se spousti na akceptacnim prostredi.')  

    println('Test se spousti na neznamem prostredi.')  




WebUI.waitForElementVisible(findTestObject(‘IB/Login/selectbox_Language’), 10)
WebUI.waitForElementClickable(findTestObject(‘IB/Login/selectbox_Language’), 10)

‘Volba jazykove mutace.’
switch (Language) {
case ‘CZ’:
println(‘Zvolena ceska jazykova mutace.’)

case 'EN':  

    println('Zvolena anglicka jazykova mutace.')  

case 'SK':  

    println('Zvolena slovenska jazykova mutace.')  
    println('Zvolena neznama jazykova mutace.')  




END SCRIPT --------------------

When I run the test directly at Katalon Studio, the test is complete without any problems.

Any advice?


And when i delete line “import common.Combase as Combase”, occures same error
unable to resolve class internal.GlobalVariable
@ line 20, column 1.
import internal.GlobalVariable as GlobalVariable

Hey @3673-Milan

I found work around. I
removed *.class from gitignore and added
‘bin\lib\internal\GlobalVariable.class’ file in respository.

So whenever I have changed GlobalVariable, I add updated GlobalVariable.class file as well and it works pretty smoothly.

1 Like

Thanks Rudra, problem was solved after update Katalon to 5.4.1.