PageImpl extends com.adobe.cq.wcm.core.components.internal.models.v1.PageImpl implements Page { @Nullable @Override public NavigationItem getRedirectTarget() { if (redirectTarget == null && StringUtils.isNotEmpty(redirectTargetValue)) { redirectTarget = new RedirectItemImpl(redirectTargetValue, request); } return redirectTarget; }  @Override @JsonIgnore @Deprecated Map<String, String> getFavicons(); @Override @JsonIgnore String[] getClientLibCategoriesJsBody(); @Override @JsonIgnore String[] getClientLibCategoriesJsHead(); @Override String getAppResourcesPath(); @Override String getCssClassNames(); @NotNull @Override String[] getExportedItemsOrder(); @NotNull @Override Map<String, ? extends ComponentExporter> getExportedItems(); @Nullable @Override NavigationItem getRedirectTarget(); @Override boolean hasCloudconfigSupport(); @Override String getMainContentSelector(); static final String PN_REDIRECT_TARGET; static final String PN_MAIN_CONTENT_SELECTOR_PROP; }
@Test void testRedirectTarget() { Page page = getPageUnderTest(REDIRECT_PAGE); NavigationItem redirectTarget = page.getRedirectTarget(); assertNotNull(redirectTarget); assertEquals("Templated Page", redirectTarget.getPage().getTitle()); assertEquals("/core/content/page/templated-page.html", redirectTarget.getURL()); }