public abstract class BaseStoreTestCase extends Object
| Modifier and Type | Field and Description |
|---|---|
protected long |
companyId |
protected long |
repositoryId |
protected com.liferay.document.library.kernel.store.Store |
store |
| Constructor and Description |
|---|
BaseStoreTestCase() |
protected long companyId
protected long repositoryId
protected com.liferay.document.library.kernel.store.Store store
public void testAddFileWithBufferedInputStream()
throws Exception
Exceptionpublic void testAddFileWithByteArrayInputStream()
throws Exception
Exceptionpublic void testAddFileWithFileInputStream()
throws Exception
Exceptionpublic void testAddFileWithUnsyncByteArrayInputStream()
throws Exception
Exceptionpublic void testCopyFileVersionDuplicateFileException()
throws Exception
Exceptionpublic void testCopyFileVersionNoSuchFileException()
throws Exception
Exceptionpublic void testDeleteDirectoryWithTwoLevelDeep()
throws Exception
Exceptionpublic void testDeleteFileWithVersion()
throws Exception
Exceptionpublic void testGetFileAsBytesNoSuchFileException()
throws Exception
Exceptionpublic void testGetFileAsStreamWithVersion()
throws Exception
Exceptionpublic void testGetFileNamesWithDirectoryOneLevelDeep()
throws Exception
Exceptionpublic void testGetFileNamesWithDirectoryTwoLevelDeep()
throws Exception
Exceptionpublic void testGetFileNamesWithInvalidDirectory()
public void testGetFileNamesWithInvalidRepository()
throws Exception
Exceptionpublic void testGetFileNamesWithTwoLevelsDeep()
throws Exception
Exceptionpublic void testGetFileSizeNoSuchFileException()
throws Exception
Exceptionpublic void testGetFileVersionAsBytesNoSuchFileException()
throws Exception
Exception@ExpectedLogs(expectedLogs=@ExpectedLog(expectedLog="Unable to delete file {companyId=",expectedType=PREFIX), level="WARN", loggerClass=com.liferay.document.library.kernel.store.BaseStore.class) public void testLogFailedDeletion()
@ExpectedLogs(expectedLogs=@ExpectedLog(expectedLog="Unable to delete file {companyId=",expectedType=PREFIX), level="WARN", loggerClass=com.liferay.document.library.kernel.store.BaseStore.class) public void testLogFailedDeletionWithVersionLabel()
public void testUpdateFileVersionDuplicateFileException()
throws Exception
Exceptionpublic void testUpdateFileVersionNoSuchFileException()
throws Exception
Exceptionpublic void testUpdateFileVersionWithNewFileName()
throws Exception
Exceptionpublic void testUpdateFileWithByteArray()
throws Exception
Exceptionpublic void testUpdateFileWithInputStream()
throws Exception
Exceptionpublic void testUpdateFileWithNewFileName()
throws Exception
Exceptionpublic void testUpdateFileWithNewFileNameDuplicateFileException()
throws Exception
Exceptionpublic void testUpdateFileWithNewFileNameNoSuchFileException()
throws Exception
Exceptionpublic void testUpdateFileWithNewRepositoryId()
throws Exception
Exceptionpublic void testUpdateFileWithNewRepositoryIdDuplicateFileException()
throws Exception
Exceptionpublic void testUpdateFileWithNewRepositoryIdNoSuchFileException()
throws Exception
Exceptionprotected void addVersions(String fileName, int newVersionCount) throws Exception
Exceptionprotected File createFile(byte[] fileData) throws IOException
IOExceptionprotected abstract String getStoreType()