groovy.lang.MissingPropertyException


#1

Hi,

I’m using Katalon Studio Version: 6.3.0 Build: 1
I get following exception when a Test Object has ‘$ctrl’ on XPath

Exception detail

Test Cases/New Test Case FAILED.
Reason:
groovy.lang.MissingPropertyException: No such property: ctrl for class: groovy.lang.Binding
	at com.kms.katalon.core.util.StrSubstitutor.replace(StrSubstitutor.java:41)
	at com.kms.katalon.core.testobject.ObjectRepository.lambda$0(ObjectRepository.java:261)
	at com.kms.katalon.core.testobject.ObjectRepository.findWebUIObject(ObjectRepository.java:258)
	at com.kms.katalon.core.testobject.ObjectRepository.readTestObjectFile(ObjectRepository.java:206)
	at com.kms.katalon.core.testobject.ObjectRepository.findTestObject(ObjectRepository.java:174)
	at com.kms.katalon.core.testobject.ObjectRepository.findTestObject(ObjectRepository.java:127)
	at com.kms.katalon.core.testobject.ObjectRepository$findTestObject.callStatic(Unknown Source)
	at New Test Case.run(New Test Case:22)
	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:337)
	at com.kms.katalon.core.main.TestCaseExecutor.doExecute(TestCaseExecutor.java:328)
	at com.kms.katalon.core.main.TestCaseExecutor.processExecutionPhase(TestCaseExecutor.java:307)
	at com.kms.katalon.core.main.TestCaseExecutor.accessMainPhase(TestCaseExecutor.java:299)
	at com.kms.katalon.core.main.TestCaseExecutor.execute(TestCaseExecutor.java:233)
	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 TempTestCase1565731520016.run(TempTestCase1565731520016.groovy:21)

Test Cases/New Test Case

import static com.kms.katalon.core.testobject.ObjectRepository.findTestObject
import com.kms.katalon.core.webui.keyword.WebUiBuiltInKeywords as WebUI

WebUI.navigateToUrl('https://run.plnkr.co/oeolQ0KY5oqHZUbb/')
WebUI.waitForElementPresent(findTestObject('Object Repository/NewTestObject'), 0)

Object Repository/NewTestObject

<?xml version="1.0" encoding="UTF-8"?>
<WebElementEntity>
   <description></description>
   <name>NewTestObject</name>
   <tag></tag>
   <elementGuidId>2cbfdd0c-fe9b-4d8c-9ce9-ff9a5140e990</elementGuidId>
   <selectorCollection>
      <entry>
         <key>XPATH</key>
         <value>//input[@ng-model=&quot;$ctrl.name&quot;]</value>
      </entry>
      <entry>
         <key>BASIC</key>
         <value></value>
      </entry>
   </selectorCollection>
   <selectorMethod>XPATH</selectorMethod>
   <useRalativeImagePath>false</useRalativeImagePath>
</WebElementEntity>

Thanks,


#2

Hi @kaz,

Please update to v6.3.2 and try again. We are sorry for this issue.

Thanks