Issue
Does anyone know how to test the navigation drawer with Kakao? I have simple activity and 2 fragments. I use Jetpack navigation components and want to test it.
Solution
class FormScreen : Screen<FormScreen>() {
val drawerLayout = KView { withId(R.id.drawer_layout) }
val navigationView = KNavigationView { withId(R.id.nav_view) }
val textKK = KTextView { withId(R.id.text_home) }
val fromTV = KTextView { withId(R.id.progressBar2) }
}
@Test
fun drawNavigationFromTasksToStatistics() {
// start up Tasks screen
val activityScenario = ActivityScenario.launch(MainActivity::class.java)
dataBindingIdlingResource.monitorActivity(activityScenario)
onScreen<FormScreen>{
drawerLayout{
perform {
navigateTo(R.id.nav_home)
}
}
textKK.isDisplayed()
}
Answered By - Nurseyit Tursunkulov
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.