Fix overrides of the findViewById in android tests for platform 26
This commit is contained in:
committed by
Vyacheslav Gerasimov
parent
587f76251e
commit
7120fe190a
Vendored
+2
-2
@@ -20,8 +20,8 @@ class MyActivity(): Activity() {
|
||||
val loginItem = Button(this)
|
||||
|
||||
val entity = MyEntity(object : FrameLayout(this) {
|
||||
override fun findViewById(id: Int) : View? = when(id) {
|
||||
R.id.login -> loginItem
|
||||
override fun <T : View> findViewById(id: Int): T? = when(id) {
|
||||
R.id.login -> loginItem as T
|
||||
else -> null
|
||||
}
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user