[ADD] Comments
This commit is contained in:
@@ -24,6 +24,7 @@ public class LocationFragmentTest {
|
||||
|
||||
@Test
|
||||
public void clickBackButton() throws Exception{
|
||||
//Here we click the back button and then we check if the homeFragment is shown
|
||||
mActivityTestRule.getActivity().getSupportFragmentManager().beginTransaction().replace(R.id.mainActivity, new LocationFragment()).commit();
|
||||
onView(withId(R.id.location_back_button)).perform(click());
|
||||
onView(withId(R.id.homeFragment)).check(matches(isDisplayed()));
|
||||
@@ -32,6 +33,7 @@ public class LocationFragmentTest {
|
||||
|
||||
@Test
|
||||
public void clickDetailButton() throws Exception{
|
||||
//Here we click an item in the recyclerview and then check if the routeDetailFragment is called
|
||||
mActivityTestRule.getActivity().getSupportFragmentManager().beginTransaction().replace(R.id.mainActivity, new LocationFragment()).commit();
|
||||
onView(withId(R.id.location_recyclerview)).perform(RecyclerViewActions.actionOnItemAtPosition(1, click()));
|
||||
onView(withId(R.id.locationDetailFragment)).check(matches(isDisplayed()));
|
||||
|
||||
Reference in New Issue
Block a user