在自动化中,当我们使用 CSS 定义页面元素时,我们可以为示例页面元素定义如下方式:
element :fld_page_element, "#uniqueID .some-class-name"
或者,
element :fld_page_element, "[id='uniqueID'] [class='some-class-name']"
其中 # 符号代表 ID 和 . 表示类属性名。
当测试自动化出现时,它们在性能方面有什么区别?或者使用比其他有什么优势?如果是,请与我分享。