How to get the css style of text-overflow in robot framework

后端 未结 2 1547
情话喂你
情话喂你 2020-12-22 02:51

How to get the css style of text-overflow in robot framework. For validating the ellipsis text.



        
2条回答
  •  甜味超标
    2020-12-22 03:23

    in robot framework to get text you can use, this will store text in variable data

    ${data}    Get Text    xpath=*//td[@class='fontStyle' and @data-placement='top']
    

    this will give you data variable as 123456789123456789qwertyuiasdfghjklzxcvbnmasdfghjkqwertyuiasdfghjkzxcvbnmertyui

    for validation you can use

    for partial match use :

    Element Should Contain    locator    text_should_check_with
    

    for exact match use :

    Element Text Should Be    locator    text_should_check_with
    

提交回复
热议问题