您好,登錄后才能下訂單哦!
當(dāng)創(chuàng)建一個(gè)UiScrollable對(duì)象時(shí),如果指定的參數(shù)是new UiSelector().scrollable(true),那么會(huì)出現(xiàn)以下問題
//Find out the new added note entry UiScrollable noteList = new UiScrollable( new UiSelector().scrollable(true)); //would be null if the scrollable widget's not more than one page UiObject note = null;
note = noteList.getChildByText(new UiSelector().className("android.widget.TextView"), "Note1", true);
<pre name="code" class="java"> assertThat(note,notNullValue());note.longClick();
//Find out the new added note entry UiScrollable noteList = new UiScrollable( new UiSelector().scrollable(true)); UiObject note = null;
if(noteList.exists()) { note = noteList.getChildByText(new UiSelector().className("android.widget.TextView"), "Note1", true); } else { note = new UiObject(new UiSelector().text("Note1")); } assertThat(note,notNullValue()); note.longClick();
//Find out the new added note entry UiScrollable noteList = new UiScrollable( new UiSelector().className("android.widget.ListView")); UiObject note = null; note = noteList.getChildByText(new UiSelector().className("android.widget.TextView"), "Note1", true); assertThat(note,notNullValue()); note.longClick();
作者 | 自主博客 | 微信 | CSDN |
天地會(huì)珠海分舵 | http://techgogogo.com | 服務(wù)號(hào):TechGoGoGo 掃描碼:
| 向AI問一下細(xì)節(jié) 免責(zé)聲明:本站發(fā)布的內(nèi)容(圖片、視頻和文字)以原創(chuàng)、轉(zhuǎn)載和分享為主,文章觀點(diǎn)不代表本網(wǎng)站立場,如果涉及侵權(quán)請(qǐng)聯(lián)系站長郵箱:is@yisu.com進(jìn)行舉報(bào),并提供相關(guān)證據(jù),一經(jīng)查實(shí),將立刻刪除涉嫌侵權(quán)內(nèi)容。 猜你喜歡最新資訊相關(guān)推薦
相關(guān)標(biāo)簽AI
助 手 |