Closed igorwojda closed 4 years ago
Workaround
fun KTextInputLayout.hasHint(@StringRes resId: Int) {
hasHint(getResourceString(resId))
}
private fun getResourceString(@StringRes resId: Int): String {
val targetContext: Context = InstrumentationRegistry.getInstrumentation().targetContext
return targetContext.resources.getString(resId)
}
Hey there! Thanks for reaching out! That proposal sounds valid and useful, and I encourage you to submit a PR 👍
CONTRIBUTING.md
file is a bit incomplete
points 1-3 are fine, but
./gradlew test
?)git ls-files -z | while IFS= read -rd '' f; do tail -c1 < "$f" | read -r _ || echo >> "$f"; done
messes up with a lot of files untouched by PRAlso after running TextInputLayoutTest
tests from IDE
I got this error 🤔
It seems that we need to revise contribution instructions 👍
Close: #219
PR with this feature has been merged
Now in
TextInputLayoutAssertions
we only have a way to verity hint by using stringfun hasHint(hint: String)
It would be nice to also have a way to use resource (to match
TextViewAssertions
class)hasHint(@StringRes resId: Int)