### Question:
ApplicationModel { public boolean hasPage(final String pageToken) { try { applicationApi.getApplicationPage(application.getToken(), pageToken); return true; } catch (final ApplicationPageNotFoundException e) { return false; } } ApplicationModel(
            final ApplicationAPI applicationApi,
            final PageAPI pageApi,
            final ProfileAPI profileApi,
            final Application application,
            final MenuFactory factory); long getId(); String getApplicationLayoutName(); String getApplicationThemeName(); Long getApplicationThemeId(); String getApplicationHomePage(); boolean hasPage(final String pageToken); boolean authorize(final APISession session); boolean hasProfileMapped(); Page getCustomPage(final String pageToken); List<Menu> getMenuList();  }### Answer:
@Test public void should_hasPage_return_true() throws Exception { given(applicationApi.getApplicationPage("token", "pageToken")).willReturn(new ApplicationPageImpl(1, 1, "pageToken")); assertThat(model.hasPage("pageToken")).isEqualTo(true); }
@Test public void should_hasPage_return_false() throws Exception { given(applicationApi.getApplicationPage("token", "pageToken")).willThrow(new ApplicationPageNotFoundException("")); assertThat(model.hasPage("pageToken")).isEqualTo(false); }