@Test
public void itReturnsToPreviousActivityOnPressHomeButton() {

  MenuItem homeButton = mock(MenuItem.class);
  when(homeButton.getItemId()).thenReturn(android.R.id.home);
  AudioPlayerActivity activity = spy(createActivity());
  activity.onOptionsItemSelected(homeButton);
  verify(activity).onBackPressed();
}