Web Recorder doesn't execute testcase with variables

*Summary
I like to record by first adding calls to existing test-cases(i.e. login), then opening the web recorder and first executing the added tests before recording further steps.

The login test in question usually uses global variables for login data. In this case I defined local variables in the test case that I am trying to pass as Input. It works fine for executing the test case outside of the web-recorder. But when I press run inside the web-recorder, I get the following Error.

*Steps to reproduce

  1. Create test case with global variables
  2. Call said test case in another test, passing local variables
  3. Start web-recorder PLUS for the second test
  4. press run

*Expected Results

succesfully executing the test case the exact same way it works outside the web-recorder

*Actual Results

This Error

2025-03-20 06:24:17.497 INFO c.k.k.c.l.logback.LogbackConfigurator - Logback default configuration initialized from: C:\Users\magadmin.katalon\packages\KS-11.0.1\configuration\org.eclipse.osgi\148\0.cp\resources\logback\logback-execution.xml
2025-03-20 06:24:17.504 INFO c.k.k.c.l.logback.LogbackConfigurator - Logback custom configuration initialized from: C:\Users\magadmin\Katalon Studio\TIMEBASE4.KATALON\TIMEBASE4.KATALON\TB4-Testautomation\Include\config\log.properties
2025-03-20 06:24:18.475 INFO c.k.k.core.main.WSVerificationExecutor - --------------------
2025-03-20 06:24:18.476 INFO c.k.k.core.main.WSVerificationExecutor - START Verification
2025-03-20 06:24:18.813 DEBUG testcase. - 1: callTestCase(findTestCase(“TBWA/Azure/Login”), [“username”:username, “password”:password], STOP_ON_FAILURE)
2025-03-20 06:24:18.936 ERROR c.k.k.core.main.WSVerificationExecutor - ❌ Verification FAILED.
Reason:
groovy.lang.MissingPropertyException: No such property: username for class: WSVerification1742448258619
at WSVerification1742448258619.run(WSVerification1742448258619:36)
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.WSVerificationExecutor.runScript(WSVerificationExecutor.java:166)
at com.kms.katalon.core.main.WSVerificationExecutor.doExecute(WSVerificationExecutor.java:161)
at com.kms.katalon.core.main.WSVerificationExecutor.processExecutionPhase(WSVerificationExecutor.java:144)
at com.kms.katalon.core.main.WSVerificationExecutor.accessMainPhase(WSVerificationExecutor.java:136)
at com.kms.katalon.core.main.WSVerificationExecutor.execute(WSVerificationExecutor.java:118)
at com.kms.katalon.core.main.TestCaseMain.runWSVerificationScript(TestCaseMain.java:174)
at TempTestCase1742448253535.run(TempTestCase1742448253535.groovy:25)
at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:103)

2025-03-20 06:24:18.948 INFO c.k.k.core.main.WSVerificationExecutor - END Verification


*Operating System
Windows Server 2025

*Katalon Studio version
Version 11.01

Environment (for Web Testing)
Chrome Version 145.0.7632.75

2 Likes

Hi there, and thanks for posting in the Katalon community! :hugs:

To help you faster, please review our guide on Record Web Utility here: Record Web utility in Katalon Studio | Katalon Docs. Double-checking the steps and configurations might resolve the issue.

If the doc doesn’t help, feel free to provide more details, and a community member will assist you soon.

Thanks for being a part of our community!
Best,
Elly Tran

Welcome to our community, your bug report has been brought up to our team. Kindly look around for any possible workaround or solutions. :partying_face:

This message tells that

  • you executed the class WSVerification1742448258619
  • the class executed a statement
callTestCase(findTestCase(“TBWA/Azure/Login”), [“username”:username, “password”:password], STOP_ON_FAILURE)
  • there was no property named username defined in the WSVerification1742448258619 class
  • so it failed.

That’s all.

@mae1

You wrote:

*Steps to reproduce

  1. Create test case with global variables
  2. Call said test case in another test, passing local variables
  3. Start web-recorder PLUS for the second test
  4. press run

It seems that you, @mae1, expect that the local variable username created in the first test case will be/should be passed to the next session of web-recorder PLUS somehow.

This will never be the case.

You misunderstand the web-recorder PLUS tool. You expect something that is not actually implemented in the tool.

1 Like

@mae1

This is a known behavior difference between normal execution and Web Recorder (Recorder Plus) execution in Katalon Studio.

The key issue is:

:cross_mark: MissingPropertyException: No such property: username

This means that during Web Recorder execution, your local variables (username, password) are not available in the temporary verification script context (WSVerificationXXXX).


Why This Happens

When you press Run inside Web Recorder Plus, Katalon:

  1. Generates a temporary script (TempTestCaseXXXX)

  2. Wraps it inside a WSVerification executor

  3. Executes it in a different runtime context

:warning: That context does NOT automatically inherit:

  • Local variables defined in your test case

  • Test case binding variables

  • Some runtime variable scopes

Outside the recorder → works fine
Inside recorder → variables are not resolved


Root Cause

This line:

callTestCase(findTestCase("TBWA/Azure/Login"), 
    ["username": username, "password": password], 
    STOP_ON_FAILURE)

Inside Recorder execution:

  • username is NOT defined in that generated context

  • So Groovy throws MissingPropertyException


BEST SOLUTIONS (Ranked by Stability)


Solution 1 (Recommended): Use Explicit Local Assignment Before callTestCase

Instead of relying on test case variables, explicitly define them at the top:

String username = GlobalVariable.username
String password = GlobalVariable.password

WebUI.callTestCase(
    findTestCase("TBWA/Azure/Login"),
    ["username": username, "password": password],
    FailureHandling.STOP_ON_FAILURE
)

Why this works

Even if recorder context changes, variables are clearly defined in current script scope.


Solution 2 (More Stable): Pass Values Directly Without Intermediate Variables

WebUI.callTestCase(
    findTestCase("TBWA/Azure/Login"),
    [
        "username": GlobalVariable.username,
        "password": GlobalVariable.password
    ],
    FailureHandling.STOP_ON_FAILURE
)

:light_bulb: This is usually the safest when using Recorder Plus.


Solution 3: Convert Login Test to Custom Keyword (Enterprise-Level Approach)

Instead of calling test case, move login logic to:

Keywords/Auth/Login.groovy
@Keyword
def login(String username, String password) {
    WebUI.setText(findTestObject('username_field'), username)
    WebUI.setText(findTestObject('password_field'), password)
    WebUI.click(findTestObject('login_button'))
}

Then call:

CustomKeywords.'Auth.Login.login'(
    GlobalVariable.username,
    GlobalVariable.password
)

Why this is best long-term

  • No variable binding issue

  • No recorder context issue

  • Cleaner architecture

  • Faster execution

  • Better maintainability

Since you work professionally in automation (Katalon + Playwright), this is actually the architecture I recommend for you long term.


What I Personally Recommend For You

Based on your experience level:

:backhand_index_pointing_right: Stop using test-case-calling for login

:backhand_index_pointing_right: Move login into a reusable Custom Keyword

This will:

  • Fix Recorder issue

  • Improve maintainability

  • Avoid variable binding bugs

  • Improve execution speed

  • Align with framework-level automation standards


Why This Error Mentions WSVerification?

Because Recorder internally uses:

WSVerificationExecutor

Even for web test case pre-execution.

So it is NOT actually a Web Service issue — it is just how Recorder engine executes scripts.


If You Want a Quick Temporary Fix (Without Refactoring)

Before starting Recorder:

  1. Hardcode temporary values:
def username = "testuser"
def password = "testpass"

If it runs → confirms it’s purely scope issue.

1 Like