Can't run testcase with custom keywords on console mode. Please help


I have a test suite that has a test case which uses PDF custom keyword plugin. If I use Katalon Studio client I can run the test suite or the test case separately just fine without any problems but I when I run the test in console mode I get this error:

2019-08-15 11:58:06.378 INFO c.k.katalon.core.main.TestCaseExecutor - START Test Cases/Private advice/Test PDF 2
2019-08-15 11:58:07.473 DEBUG testcase.Test PDF 2 - 1: path
= getProjectDir() + “/Data Files/”
2019-08-15 11:58:07.492 DEBUG testcase.Test PDF 2 - 2: com.
kms.katalon.keyword.pdf.PDF.getPageNumber(path + “F540107.pdf”)
2019-08-15 11:58:07.502 ERROR k.k.c.m.CustomKeywordDelegatingMetaClass - ? com.kms.katalon.keyword.pdf.PDF
2019-08-15 11:58:07.505 ERROR c.k.katalon.core.main.TestCaseExecutor - ? Test Cases/Private advice/Test PDF 2 FAILED.2019-08-15 11:58:07.509 INFO c.k.katalon.core.main.TestCaseExecutor - END Test Cases/Private advice/Test PDF 2

java.lang.ClassNotFoundException: com.kms.katalon.keyword.pdf.PDF
at com.kms.katalon.core.main.CustomKeywordDelegatingMetaClass.getCustomKeywordClassAndSetMetaClass(
at com.kms.katalon.core.main.CustomKeywordDelegatingMetaClass.invokeStaticMethod(
at Test PDF PDF 2:33)
at com.kms.katalon.core.main.ScriptEngine.runScriptAsRawText(
at com.kms.katalon.core.main.TestCaseExecutor.runScript(
at com.kms.katalon.core.main.TestCaseExecutor.doExecute(
at com.kms.katalon.core.main.TestCaseExecutor.processExecutionPhase(Test
at com.kms.katalon.core.main.TestCaseExecutor.accessMainPhase(
at com.kms.katalon.core.main.TestCaseExecutor.execute(
at com.kms.katalon.core.main.TestSuiteExecutor.accessTestCaseMainPhase(
at com.kms.katalon.core.main.TestSuiteExecutor.accessTestSuiteMainPhase(
at com.kms.katalon.core.main.TestSuiteExecutor.execute(
at com.kms.katalon.core.main.TestCaseMain.startTestSuite(
at com.kms.katalon.core.main.TestCaseMain$startTestSuite$ Source)

Any feedback is much obliged. Thanks.

1 Like

What your command line execution code ? Did you add the apiKey to it ?


Ah this fixed the problem! I’m able to run the tests in console mode now.

What an odd fix. Why wouldn’t the plugin work without the APIkey?

thank you so much!

The apikey make sure you have active subscription when using paid plugin. It’s just the same architecture used for all plugin even free one.

What Happens when your API-Key Server is local instead of at Might that affect the ability to run the plugins?