-
-
Notifications
You must be signed in to change notification settings - Fork 120
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Create methods to avoid knowing the ID of the ViewPager if there's only one ViewPager #58
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Awesome idea!
|
||
@NonNull | ||
public static Matcher<View> displayedAssignableFrom(final Class<? extends View> clazz) { | ||
return allOf(isDisplayed(), isAssignableFrom(clazz)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Suggestion: A nice trick to avoid the ugly clazz
hack is telling what it's for. Like viewClass
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice! Actually, I copied it from the original isAssignableFrom
method... but your idea is better :·)
@@ -31,6 +31,8 @@ dependencies { | |||
} | |||
compile 'com.android.support.test.uiautomator:uiautomator-v18:2.1.2' | |||
compile 'com.android.support:support-annotations:25.1.0' | |||
compile 'com.android.support:support-core-ui:25.1.0' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Q: Why is this new dependency for?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For ViewPager
😮
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Aaaaaah I get it now.
Thanks!
The original idea? Look here! #8