我正在尝试将方法从一个自定义关键字调用到另一个自定义关键字函数
但我得到的错误,
05-30-2018 02:59:02 PM - [开始] - 开始动作: mandatoryfield_Validation.Mandatoryfieldvalidation.textfieldvalidation 05-30-2018 02:59:02 PM - [INFO] - 查找带有id'对象的测试对象 存储库/ HelpDeskModule /硕士/团队/ Page_eFACiLiTY / input_Txt_Code' 05-30-2018 02:59:02 PM - [ERROR] - 没有这样的属性:CustomKeywords for class:mandatoryfield_Validation.Mandatoryfieldvalidation 05-30-2018 02:59:02 PM - [结束] - 结束动作: mandatoryfield_Validation.Mandatoryfieldvalidation.textfieldvalidation 05-30-2018 02:59:02 PM - [错误] - 测试 Cases / HelpDeskModule / Master / Team_ / Team FAILED因为(of)Variable ' CustomKeywords'没有为测试用例定义。
请找到以下代码
public class Mandatoryfieldvalidation {
//<!--Initializing object-->
private static Connection connection = null;
private static String columntype;
private static int num;
private static int datatypevalue
def driver = DF.getWebDriver()
KeywordLogger logger = new KeywordLogger()
JavascriptExecutor js = ((driver) as JavascriptExecutor)
//Method for validating textfield
@Keyword
def void textfieldvalidation()
{
CustomKeywords.'alerthandling.verifyalertpresent.verifyalert'()
}
}