app/src/androidTest/java/fr/neamar/kiss/androidTest/MainActivityTest.java
// Searching for something, then displaying and hiding the search bar, should empty query
Searching for something, then displaying and hiding the search bar, should empty query
Searching for something then displaying and hiding the search bar should empty query
@Test
    public void testKissBarEmptiesSearch() {
        onView(withId(R.id.searchEditText)).perform(typeText("Test"));
        onView(withId(R.id.searchEditText)).check(matches(withText("Test")));
        onView(withId(R.id.launcherButton)).perform(click());
        onView(withId(R.id.mainKissbar)).check(matches(isDisplayed()));
        onView(withId(R.id.whiteLauncherButton)).perform(click());
        onView(withId(R.id.searchEditText)).check(matches(withText("")));
    }
@ Test public void testKissBarEmptiesSearch ( ) { onView ( withId ( R . id . searchEditText ) ) . perform ( typeText ( "Test" ) ) ; onView ( withId ( R . id . searchEditText ) ) . check ( matches ( withText ( "Test" ) ) ) ; onView ( withId ( R . id . launcherButton ) ) . perform ( click ( ) ) ; onView ( withId ( R . id . mainKissbar ) ) . check ( matches ( isDisplayed ( ) ) ) ; onView ( withId ( R . id . whiteLauncherButton ) ) . perform ( click ( ) ) ; onView ( withId ( R . id . searchEditText ) ) . check ( matches ( withText ( "" ) ) ) ; }
Searching for something, then displaying and hiding the search bar, should empty query
Searching for something then displaying and hiding the search bar should empty query
// Sanity check