OnboardingScreenPresenter extends OnboardingScreenContract.Presenter { @Override public void start() { getView().showPages(mPages, mShowEmptyLastPage); mCurrentPageIndex = 0; getView().scrollToPage(mCurrentPageIndex); getView().activatePageIndicatorForPage(mCurrentPageIndex); trackOnboardingScreenEvent(OnboardingScreenEvent.START); } OnboardingScreenPresenter(@NonNull final Activity activity,
            @NonNull final OnboardingScreenContract.View view); @Override void start(); @Override void stop(); @Override void setListener(@NonNull final OnboardingFragmentListener listener);  }
@Test public void should_scrollToFirstPage_onStart() throws Exception { final OnboardingScreenPresenter presenter = createPresenter(); presenter.start(); verify(mView).scrollToPage(0); }
@Test public void should_activatePageIndicator_forFirstPage_onStart() throws Exception { final OnboardingScreenPresenter presenter = createPresenter(); presenter.start(); verify(mView).activatePageIndicatorForPage(0); }
@Test public void should_triggerStartEvent() throws Exception { final OnboardingScreenPresenter presenter = createPresenter(); final EventTracker eventTracker = spy(EventTracker.class); new GiniVision.Builder().setEventTracker(eventTracker).build(); presenter.start(); verify(eventTracker).onOnboardingScreenEvent(new Event<>(OnboardingScreenEvent.START)); }