Skip to content

Commit

Permalink
adapt Log tests to new Log implementation
Browse files Browse the repository at this point in the history
  • Loading branch information
jesmrec committed Nov 28, 2019
1 parent 4269232 commit 43fca1a
Showing 1 changed file with 14 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -42,15 +42,24 @@ class OCSettingsLogTest {
val activityRule = ActivityTestRule(LogHistoryActivity::class.java, true, true)

@Test
fun checkTitle() {
onView(withText(R.string.actionbar_logger)).check(matches(isDisplayed()))
fun itemsToolbar() {
onView(withId(R.id.search_button)).check(matches(isDisplayed()))
onView(withId(R.id.menu_share)).check(matches(isDisplayed()))
onView(withId(R.id.menu_clear)).check(matches(isDisplayed()))
//Values not i18n
onView(withText("LOGCAT")).check(matches(isDisplayed()))
onView(withText("LOGFILE")).check(matches(isDisplayed()))
}

@Test
fun itemsToolbar() {
onView(withId(R.id.menu_search)).check(matches(isDisplayed()))
fun itemsLogLevel() {
openActionBarOverflowOrOptionsMenu(InstrumentationRegistry.getInstrumentation().targetContext)
onView(withText("Logcat")).check(matches(isDisplayed()))
//Values not i18n
onView(withText("Verbose")).check(matches(isDisplayed()))
onView(withText("Debug")).check(matches(isDisplayed()))
onView(withText("Info")).check(matches(isDisplayed()))
onView(withText("Warning")).check(matches(isDisplayed()))
onView(withText("Error")).check(matches(isDisplayed()))
}

}

0 comments on commit 43fca1a

Please sign in to comment.