public class EspAdapterViewItem extends EspView
Actions and assertions for AdapterView items including ChildViews and AdapterItems.
Some actions and assertions can only be used when accessing the item by visible index or adapter index. Recommend is to use more specific elements like EspListViewItem.
| Constructor and Description |
|---|
EspAdapterViewItem(EspAdapterViewItem template)
Create new instance based on given element matcher.
|
EspAdapterViewItem(org.hamcrest.Matcher<android.view.View> base,
int adapterViewId,
int index,
de.nenick.espressomacchiato.elements.EspAdapterViewItem.Mode mode)
Create new instance.
|
| Modifier and Type | Method and Description |
|---|---|
protected org.hamcrest.Matcher<android.view.View> |
baseMatcherForItemChild(org.hamcrest.Matcher<android.view.View> childMatcher)
Base for matching a view inside this item.
|
static EspAllOfBuilder<EspView> |
byAll()
Deprecated.
Currently not supported please use a different element creator.
|
static EspView |
byId(int resourceId)
Deprecated.
Currently not supported please use a different element creator.
|
static EspAdapterViewItem |
byItemIndex(int adapterViewId,
int index)
Create new instance based on adapter index.
|
static EspAdapterViewItem |
byVisibleIndex(int adapterViewId,
int index)
Create new instance based on visible index.
|
void |
scrollTo()
Make the item visible.
|
assertIsDisabled, assertIsDisplayedOnScreen, assertIsEnabled, assertIsHidden, assertIsNotSelected, assertIsPartiallyDisplayedOnly, assertIsPartiallyDisplayedOnScreen, assertIsSelected, assertIsVisible, assertNotExist, baseMatcher, click, createMatcherList, doubleClick, findView, findView, longClick, swipeDown, swipeUppublic EspAdapterViewItem(org.hamcrest.Matcher<android.view.View> base,
int adapterViewId,
int index,
de.nenick.espressomacchiato.elements.EspAdapterViewItem.Mode mode)
Create new instance.
base - For Mode#byItemIndex use AdapterView base matcher. For Mode#byVisibleIndex use EspAdapterViewItemMatcher.adapterViewId - Adapter view containing this item.index - Item index for doing actions or assertions.mode - Choose an index Mode.public EspAdapterViewItem(EspAdapterViewItem template)
Create new instance based on given element matcher.
template - Pre configured element matcher.public static EspAdapterViewItem byItemIndex(int adapterViewId, int index)
Create new instance based on adapter index.
adapterViewId - Adapter view containing this item.index - Item index for doing actions or assertions.public static EspAdapterViewItem byVisibleIndex(int adapterViewId, int index)
Create new instance based on visible index.
adapterViewId - Adapter view containing this item.index - Item index for doing actions or assertions.public void scrollTo()
Make the item visible.
Does only work when this item is accessed by adapter index.
protected org.hamcrest.Matcher<android.view.View> baseMatcherForItemChild(org.hamcrest.Matcher<android.view.View> childMatcher)
Base for matching a view inside this item.
Does only work when this item is accessed by visible index.
childMatcher - Matcher for any item child view.@Deprecated public static EspAllOfBuilder<EspView> byAll()
@Deprecated public static EspView byId(int resourceId)