2016-11-11 102 views

回答

0

在Sikuli沒有辦法做到這一點。我可以推薦你使用Selenium。這是Web測試的最佳框架。

0

我會這樣做的擊鍵。選擇全部,使用剪貼板複製粘貼。

click("url.png") # select the url location; may be a bit iffy/browser dependent 
type("a", KEY_CTRL) # select all 
type("c", KEY_CTRL) # copy to clipboard 
click("target.png") # go to your target 
type("v", KEY_CTRL) # and paste 

參考:
http://doc.sikuli.org/keys.html

+0

選擇地址欄通常也可以使用Ctrl + L鍵來完成,見http://www.computerhope.com/tips /tip18.htm – Bookeater

0

簡單的解決方案

click(your link);sleep(2) # or wait for loading to finish via an exists() 
type("l",Key.CTRL) # hotkey for address bar selection on FF and GC 
type("c",Key.CTRL) #copies