Select_list元素
HTML tag - <select>
可以用來(lái)定位的方法有:
Browser.select(:class, “select class”)
Browser.select(:id, “select id”)
Browser.select(:index, 0)
Browser.select(:name, “select name”)
Browser.select(:text, “select text”)
Browser.select(:value, “select value”)
Browser.select(:xpath, “select xpath”)
Browser.select(:class=>“select class name”, :index, 0) (Mulitple Attributes)
Span元素
HTML tag - <span>
可以用來(lái)定位的方法有:
Browser.span(:class, “span class”)
Browser.span(:id, “span id”)
Browser.span(:index, 0)
Browser.span(:name, “span name”)
Browser.span(:text, “span text”)
Browser.span(:xpath, “span xpath”)
Browser.span(:class=>“span class name”, :index, 0) (Mulitple Attributes)
Table元素
HTML tag - <table>
可以用來(lái)定位的方法有:
Browser.table(:class, “table class”)
Browser.table(:id, “table id”)
Browser.table(:index, 0)
Browser.table(:name, “table name”)
Browser.table(:text, “table text”)
Browser.table(:xpath, “table xpath”)
Browser.table(:class=>“table class name”, :index, 0)(Mulitple Attributes)
Text_field元素
HTML tag - <input type=”password”>/<input type=”text”>