public abstract class BaseTrashHandlerTestCase
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
protected com.liferay.portal.kernel.model.BaseModel<?> |
baseModel |
protected com.liferay.portal.kernel.model.Group |
group |
com.liferay.portal.search.test.util.SearchTestRule |
searchTestRule |
| Constructor and Description |
|---|
BaseTrashHandlerTestCase() |
public com.liferay.portal.search.test.util.SearchTestRule searchTestRule
protected com.liferay.portal.kernel.model.BaseModel<?> baseModel
@DeleteAfterTestRun protected com.liferay.portal.kernel.model.Group group
public void setUp()
throws java.lang.Exception
java.lang.Exceptionpublic void testDeleteTrashVersions()
throws java.lang.Exception
java.lang.Exceptionpublic void testMoveBaseModelToTrash()
throws java.lang.Exception
java.lang.Exceptionpublic void testMoveBaseModelToTrashIndexable()
throws java.lang.Exception
java.lang.Exceptionpublic void testMoveBaseModelToTrashIndexableAndReindex()
throws java.lang.Exception
java.lang.Exceptionpublic void testMoveBaseModelToTrashIndexableWithEqualsParentAndBaseModelClass()
throws java.lang.Exception
java.lang.Exceptionpublic void testMoveBaseModelToTrashIndexableWithEqualsParentAndBaseModelClassAndReindex()
throws java.lang.Exception
java.lang.Exceptionpublic void testMoveBaseModelToTrashIsNotVisible()
throws java.lang.Exception
java.lang.Exceptionpublic void testMoveBaseModelToTrashStatusIsInTrash()
throws java.lang.Exception
java.lang.Exceptionpublic void testMoveBaseModelToTrashUniqueTitleNotChange()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashAndDeleteWithApprovedStatus()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashAndDeleteWithApprovedStatusIndexable()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashAndDeleteWithApprovedStatusIndexableAndEqualsParentAndBaseModelClass()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashAndDeleteWithApprovedStatusIsNotFound()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashAndDeleteWithDraftStatus()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashAndDeleteWithDraftStatusIndexable()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashAndDeleteWithDraftStatusIsNotFound()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashAndRestoreWithApprovedStatus()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashAndRestoreWithApprovedStatusIndexable()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashAndRestoreWithApprovedStatusIndexableAndEqualsParentAndBaseModelClass()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashAndRestoreWithApprovedStatusIsVisible()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashAndRestoreWithApprovedStatusRestoreStatus()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashAndRestoreWithApprovedStatusRestoreUniqueTitle()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashAndRestoreWithDraftStatus()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashAndRestoreWithDraftStatusIndexable()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashAndRestoreWithDraftStatusIsNotVisible()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashAndRestoreWithDraftStatusRestoreStatus()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashAndRestoreWithDraftStatusRestoreUniqueTitle()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashBaseModelAndDeleteWithParentIsNotRestorable()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashBaseModelAndParentAndDeleteGroupTrashEntries()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashBaseModelAndParentAndDeleteParent()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashBaseModelAndParentAndDeleteParentNoMoveableFromTrash()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashBaseModelAndParentAndRestore()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashBaseModelAndParentAndRestoreModel()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashBaseModelAndParentAndRestoreModelIsVisible()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashBaseModelAndParentIsInContainerBaseModel()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashBaseModelAndParentIsNotVisible()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashBaseModelAndTrashParentAndDeleteParentIsNotRestorable()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashBaseModelAndTrashParentIsNotRestorable()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashBaseModelIsInTrashContainer()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashBaseModelWithParentIsRestorable()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashDuplicate()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashGrandparentBaseModel()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashGrandparentBaseModelAndRestoreParentModel()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashGrandparentBaseModelAndRestoreParentModelIsNotInTrashContainer()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashGrandparentBaseModelAndRestoreParentModelIsVisible()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashGrandparentBaseModelAndRestoreParentModelIsVisibleParent()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashGrandparentBaseModelIsNotVisible()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashGrandparentBaseModelIsNotVisibleParent()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashIsRestorableBaseModel()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashMyBaseModel()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashParent()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashParentAndBaseModel()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashParentAndDeleteGroupTrashEntries()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashParentAndDeleteParent()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashParentAndRestoreBaseModelIsVisible()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashParentAndRestoreIndexable()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashParentAndRestoreParentAndBaseModel()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashParentIndexable()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashParentIndexableAndReindex()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashParentIsNotVisible()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashParentWithBaseModelIsInTrashContainer()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashParentWithBaseModelIsIsNotVisible()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashRecentBaseModel()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashVersionBaseModel()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashVersionBaseModelAndDelete()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashVersionBaseModelAndDeleteIndexable()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashVersionBaseModelAndDeleteIndexableWithEqualsParentAndBaseModelClass()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashVersionBaseModelAndDeleteIsNotFound()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashVersionBaseModelAndRestore()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashVersionBaseModelAndRestoreIndexable()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashVersionBaseModelAndRestoreIndexableWithEqualsParentAndBaseModelClass()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashVersionBaseModelAndRestoreIsVisible()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashVersionBaseModelIndexable()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashVersionBaseModelIndexableAndReindex()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashVersionBaseModelIndexableWithEqualsParentAndBaseModelClass()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashVersionBaseModelIndexableWithEqualsParentAndBaseModelClassAndReindex()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashVersionBaseModelIsNotVisible()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashVersionParentBaseModel()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashVersionParentBaseModelAndCustomRestore()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashVersionParentBaseModelAndRestore()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashVersionParentBaseModelAndRestoreIsNotInTrashContainer()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashVersionParentBaseModelAndRestoreIsVisible()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashVersionParentBaseModelIndexable()
throws java.lang.Exception
java.lang.Exceptionpublic void testTrashVersionParentBaseModelIsNotVisible()
throws java.lang.Exception
java.lang.Exceptionprotected com.liferay.portal.kernel.model.BaseModel<?> addBaseModel(com.liferay.portal.kernel.model.BaseModel<?> parentBaseModel,
com.liferay.portal.kernel.service.ServiceContext serviceContext)
throws java.lang.Exception
java.lang.Exceptionprotected abstract com.liferay.portal.kernel.model.BaseModel<?> addBaseModelWithWorkflow(com.liferay.portal.kernel.model.BaseModel<?> parentBaseModel,
com.liferay.portal.kernel.service.ServiceContext serviceContext)
throws java.lang.Exception
java.lang.Exceptionprotected com.liferay.portal.kernel.model.BaseModel<?> addBaseModelWithWorkflow(com.liferay.portal.kernel.service.ServiceContext serviceContext)
throws java.lang.Exception
java.lang.Exceptionprotected com.liferay.portal.kernel.model.BaseModel<?> addDraftBaseModel(com.liferay.portal.kernel.model.BaseModel<?> parentBaseModel,
com.liferay.portal.kernel.service.ServiceContext serviceContext)
throws java.lang.Exception
java.lang.Exceptionprotected void deleteParentBaseModel(com.liferay.portal.kernel.model.BaseModel<?> parentBaseModel,
boolean includeTrashedEntries)
throws java.lang.Exception
java.lang.Exceptionprotected java.lang.Long getAssetClassPK(com.liferay.portal.kernel.model.ClassedModel classedModel)
protected abstract com.liferay.portal.kernel.model.BaseModel<?> getBaseModel(long primaryKey)
throws java.lang.Exception
java.lang.Exceptionprotected abstract java.lang.Class<?> getBaseModelClass()
protected java.lang.String getBaseModelClassName()
protected long getDeletionSystemEventCount(com.liferay.portal.kernel.trash.TrashHandler trashHandler,
long systemEventSetKey)
throws java.lang.Exception
java.lang.Exceptionprotected abstract int getNotInTrashBaseModelsCount(com.liferay.portal.kernel.model.BaseModel<?> parentBaseModel)
throws java.lang.Exception
java.lang.Exceptionprotected com.liferay.portal.kernel.model.BaseModel<?> getParentBaseModel(com.liferay.portal.kernel.model.Group group,
long parentBaseModelId,
com.liferay.portal.kernel.service.ServiceContext serviceContext)
throws java.lang.Exception
java.lang.Exceptionprotected com.liferay.portal.kernel.model.BaseModel<?> getParentBaseModel(com.liferay.portal.kernel.model.Group group,
com.liferay.portal.kernel.service.ServiceContext serviceContext)
throws java.lang.Exception
java.lang.Exceptionprotected int getTrashEntriesCount(long groupId)
throws java.lang.Exception
java.lang.Exceptionprotected long getTrashEntryClassPK(com.liferay.portal.kernel.model.ClassedModel classedModel)
protected com.liferay.portal.kernel.trash.TrashHandler getTrashHandler(java.lang.String className)
protected abstract java.lang.String getUniqueTitle(com.liferay.portal.kernel.model.BaseModel<?> baseModel)
protected com.liferay.portal.kernel.model.WorkflowedModel getWorkflowedModel(com.liferay.portal.kernel.model.ClassedModel baseModel)
throws java.lang.Exception
java.lang.Exceptionprotected boolean isBaseModelContainerModel()
protected boolean isInTrashContainer(com.liferay.portal.kernel.model.ClassedModel classedModel)
throws java.lang.Exception
java.lang.Exceptionprotected boolean isValidTrashTitle(java.lang.String title)
protected abstract void moveBaseModelToTrash(long primaryKey)
throws java.lang.Exception
java.lang.Exceptionprotected void reindex(com.liferay.portal.kernel.model.ClassedModel classedModel)
throws java.lang.Exception
java.lang.Exception