您好,登錄后才能下訂單哦!
/** 我的頁面通過名字跳轉到二維碼點擊分享好友
* @throws Exception
* 1、點擊我的
* 2、點擊我的名字
* 3、點擊二維碼
* 4、點擊保存
* */
public static void PersonalSettingsPagesShareFriends() throws Exception
{
Thread.sleep(5000);
driver.findElement(GetByLocator.getLocator("MyInfo")).click();
driver.manage().timeouts().implicitlyWait(10, TimeUnit.SECONDS);
driver.findElement(GetByLocator.getLocator("PrivateCardName")).click();
//#二維碼:
driver.findElement(GetByLocator.getLocator("PrivateCardNamerq")).click();
//分享
driver.findElement(GetByLocator.getLocator("QrCodeShare")).click();
/**
* 截圖*/
TJTAppiumTest.ScreenshotAsDate("QrCodeShare");
List<AndroidElement> My_FriendsList = driver.findElements(GetByLocator.getLocator("My_Friends"));
for(AndroidElement ls:My_FriendsList)
{
String My_FriendsListName = ls.getAttribute("text");
System.out.println("My_FriendsListName:" + My_FriendsListName);
if(My_FriendsListName.equals("好友"))
{
driver.findElement(GetByLocator.getLocator("My_Friends")).click();
}else if(My_FriendsListName.equals("小組")){
} else if(My_FriendsListName.equals("微信好友")){
} else if(My_FriendsListName.equals("微博")){
}else if(My_FriendsListName.equals("QQ好友")){
}else if(My_FriendsListName.equals("QQ空間")){
}else if(My_FriendsListName.equals("信息")){
}else {
System.out.println("沒有找到!!");
}
}
//driver.findElement(GetByLocator.getLocator("My_Friends")).click();
driver.manage().timeouts().implicitlyWait(10, TimeUnit.SECONDS);
driver.findElement(GetByLocator.getLocator("friend_share_contact")).click();
driver.findElement(GetByLocator.getLocator("Friends_share_search")).sendKeys("美麗的開始");//搜索好友名稱
driver.findElement(GetByLocator.getLocator("SelectTheSearchResults")).click();
driver.findElement(GetByLocator.getLocator("Share_send")).click();
TJTAppiumTest.ScreenshotAsDate("Share_send");
driver.pressKeyCode(AndroidKeyCode.BACK);
driver.pressKeyCode(AndroidKeyCode.BACK);
driver.pressKeyCode(AndroidKeyCode.BACK);
}
免責聲明:本站發布的內容(圖片、視頻和文字)以原創、轉載和分享為主,文章觀點不代表本網站立場,如果涉及侵權請聯系站長郵箱:is@yisu.com進行舉報,并提供相關證據,一經查實,將立刻刪除涉嫌侵權內容。