1
A
回答
1
1
使用TestPlan與硒後端這段代碼從谷歌抓取的建議 - 這是一個自動完成組合框的示例。
GotoURL http://www.google.com/webhp?hl=en
ClickReplaceType //input[@name='q'] what is my
# This is where the suggestions appear
set %ResultsXPath% //table[@class='gac_m']//td[@class='gac_c']
# Check that they are there (that is, wiat for them, since they are dynamic)
Check %ResultsXPath%
# Then iterate over the suggestions
foreach %Cell% in (response %ResultsXPath%)
Notice %Cell%
end
這將產生的結果:
00000000-00 GOTOURL http://www.google.com/webhp?hl=en
00000001-00 NOTICE Starting a new browser (0:0:0:0:1) [email protected]
00000002-00 NOTICE what is my ip
00000003-00 NOTICE what is my ip address
00000004-00 NOTICE what is my bmi
00000005-00 NOTICE what is my house worth
00000006-00 NOTICE what is my
通常這種測試在測試計劃的硒和後端的HtmlUnit都工作,但谷歌目前正在與硒的作品。
相關問題
- 1. 組合框自動完成
- 2. 問題在自動完成組合框
- 3. PHP中的自動完成組合框
- 4. 自動完成表中的組合框
- 5. 自動完成和引導組合框
- 6. WPF自動完成組合框
- 7. Flex自動完成組合框?
- 8. 下拉組合框不自動完成。
- 9. ExtJS的4組合框自動完成
- 10. 使用jQuery自動完成組合框
- 11. 組合框自動完成無法檢測
- 12. 如何自動完成selenium ide中的自動完成標籤?
- 13. 如何在Excel自動完成數字中製作組合框?
- 14. JQuery自動完成組合框 - 自動調整
- 15. 自動測試Python/selenium gspread
- 16. javascript中的asp.net自動完成組合框函數
- 17. ASP.NET MVC中的自動完成組合框?
- 18. 自動完成組合框 - 列表中的項目?
- 19. vb.net中的組合框自動完成問題
- 20. C中的組合框和自動完成#
- 21. 發送自定義值與jQuery UI自動完成組合框
- 22. 組合框自動完成自定義功能
- 23. 自動完成下拉測試
- 24. 自動完成文本框集合
- 25. dhtmlx組合,自動完成模式,js
- 26. p:dataTable自動完成和ColumnToggler組合
- 27. JQuery自動完成和AJAX組合
- 28. 自動從jQuery自動完成組合框中選擇一個項目
- 29. 如何創建多選擇自動完成組合框?
- 30. 沒有自動完成的C#組合框