### Question:
PageDatastore extends CommonDatastore<PageItem, Page> implements DatastoreHasAdd<PageItem>, DatastoreHasUpdate<PageItem>,
        DatastoreHasGet<PageItem>, DatastoreHasSearch<PageItem>, DatastoreHasDelete { protected PageCreator buildPageCreatorFrom(final PageItem pageItem) { final PageCreator pageCreator = new PageCreator(pageItem.getUrlToken(), pageItem.getContentName()); pageCreator.setDescription(pageItem.getDescription()); pageCreator.setDisplayName(pageItem.getDisplayName()); return pageCreator; } PageDatastore(final APISession engineSession, final WebBonitaConstantsUtils constantsValue,
            final PageAPI pageAPI,
            final CustomPageService customPageService,
            final CompoundPermissionsMapping compoundPermissionsMapping,
            final ResourcesPermissionsMapping resourcesPermissionsMapping,
            final BonitaHomeFolderAccessor tenantFolder); @Override PageItem add(final PageItem pageItem); @Override PageItem get(final APIID id); @Override void delete(final List<APIID> ids); @Override ItemSearchResult<PageItem> search(final int page, final int resultsByPage, final String search,
            final String orders,
            final Map<String, String> filters); @Override PageItem update(final APIID id, final Map<String, String> attributes); static final String UNMAPPED_ATTRIBUTE_ZIP_FILE; }### Answer:
@Test public void testBuildPageCreatorFrom() { final String testUrlTokenString = "testUrlTokenString"; final String testContentNameString = "testContentName"; final String testDescriptionString = "testDescriptionString"; final String testDisplayNameString = "testDescriptionString"; doReturn(testUrlTokenString).when(pageItem).getUrlToken(); doReturn(testContentNameString).when(pageItem).getContentName(); doReturn(testDescriptionString).when(pageItem).getDescription(); doReturn(testDisplayNameString).when(pageItem).getDisplayName(); final PageCreator pageCreator = pageDatastore.buildPageCreatorFrom(pageItem); final Map<PageField, Serializable> expectedFields = new HashMap<>(); expectedFields.put(PageField.NAME, testUrlTokenString); expectedFields.put(PageField.CONTENT_NAME, testContentNameString); expectedFields.put(PageField.CONTENT_TYPE, ContentType.PAGE); expectedFields.put(PageField.DESCRIPTION, testDescriptionString); expectedFields.put(PageField.DISPLAY_NAME, testDisplayNameString); assertThat(pageCreator.getFields()).isEqualTo(expectedFields); }