簡體   English   中英

如何使用Appium(java)在微信中自動單擊“閱讀更多”

[英]How to automatically click “read more” in the WeChat message using Appium(java)

當我使用appium + eclipse使用微信進行自動化時,我發現找不到“ Read more鏈接。 所有內容都包含在FrameLayout ,但是不能選擇所有元素。 我嘗試通過使用appdriver.tap(1, x, y, 1)命令單擊“閱讀更多”鏈接,x和y是“閱讀更多”鏈接的坐標,但是沒有用。 有什么好主意嗎? 在此處輸入圖片說明

use driver.tap(1, yourelement, 1000) 
driver.tap(int finger, WebElement, int duration) //this is the function i use above

還有一個功能,那就是

driver.tap(int finger, int x,int y, int duration) 

如果這樣做沒有幫助,您可以使用如下所示的touchaction tap:

TouchAction action = new TouchAction(driver);
action.tap(int x, int y).release().perform();

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM