【问题标题】:How can i convert below Katalon Custom Keyword in to Selenium [closed]我如何在 Katalon 自定义关键字下方转换为 Selenium [关闭]
【发布时间】:2020-01-16 10:06:06
【问题描述】:

需要将下面的Katalon代码转换成selenium,请问需要转换哪些区域?

package nasdaqKeyword
import ...


public class accesstoTable {

    private String table_date(String trid){

        return'/html[1]/body[1]/div[4]/div[1]/main[1]/div[1]/div[4]/div[2]/div[1]/div[1]/div[4]/div[2]/table[1]/tbody[1]/tr[' + trid + ']/th[1]';
    }

    private TestObject gettablevalueFirstcol(String trid){
        TestObject firstColu = new TestObject(trid);
        firstColu.addProperty("xpath", ConditionType.EQUALS,table_date(trid),true);
        return firstColu
    }

    @Keyword
    public String navigatetoGettablevalueFirstcol(String trid){
        TestObject firstColu = gettablevalueFirstcol(trid);
        WebUI.waitForElementPresent(firstColu,GlobalVariable.time_1)
        String abc = WebUI.getText(firstColu)
    }}

【问题讨论】:

    标签: selenium katalon-studio


    【解决方案1】:

    Katalon 使用 Groovy 作为底层编程语言,所有 Katalon 关键字基本上都是围绕 Selenium 代码的 Groovy 包装器。

    您可以查看this questionthis article 了解更多详情。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2019-10-31
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多