"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "src/main/java/com/openkm/test/api/DocumentTest.java" between
OpenKM-document-management-system-6.3.10.tar.gz and OpenKM-document-management-system-6.3.11.tar.gz

About: OpenKM (Knowledge Management) is a document management system that allows easy management of documents, users, roles and finding your enterprise documents and records. Community version (source code).

DocumentTest.java  (OpenKM-document-management-system-6.3.10):DocumentTest.java  (OpenKM-document-management-system-6.3.11)
skipping to change at line 102 skipping to change at line 102
assertEquals(roDoc.getPath(), roNew.getPath()); assertEquals(roDoc.getPath(), roNew.getPath());
assertEquals(Config.UNIT_TESTING_USER, roNew.getAuthor()); assertEquals(Config.UNIT_TESTING_USER, roNew.getAuthor());
assertEquals("text/plain", roNew.getMimeType()); assertEquals("text/plain", roNew.getMimeType());
catchException(okmDocument).create(token, roDoc, new ByteArrayInp utStream("sample text".getBytes())); catchException(okmDocument).create(token, roDoc, new ByteArrayInp utStream("sample text".getBytes()));
assertTrue(caughtException() instanceof ItemExistsException); assertTrue(caughtException() instanceof ItemExistsException);
} }
@Test @Test
public void testCreateSimple() throws IOException, UnsupportedMimeTypeExc eption, FileSizeExceededException, UserQuotaExceededException, public void testCreateSimple() throws IOException, UnsupportedMimeTypeExc eption, FileSizeExceededException, UserQuotaExceededException,
VirusDetectedException, ItemExistsException, PathNotFound Exception, AccessDeniedException, RepositoryException, VirusDetectedException, ItemExistsException, PathNotFound Exception, AccessDeniedException, RepositoryException,
DatabaseException, ExtensionException, AutomationExceptio n { DatabaseException, ExtensionException, AutomationExceptio n, LockException {
String locContent = "Sample text"; String locContent = "Sample text";
Document piNew = okmDocument.createSimple(token, BASE + "/pi.txt" , new ByteArrayInputStream(locContent.getBytes())); Document piNew = okmDocument.createSimple(token, BASE + "/pi.txt" , new ByteArrayInputStream(locContent.getBytes()));
assertNotNull(piNew); assertNotNull(piNew);
assertEquals(BASE + "/pi.txt", piNew.getPath()); assertEquals(BASE + "/pi.txt", piNew.getPath());
assertEquals(Config.UNIT_TESTING_USER, piNew.getAuthor()); assertEquals(Config.UNIT_TESTING_USER, piNew.getAuthor());
assertEquals("text/plain", piNew.getMimeType()); assertEquals("text/plain", piNew.getMimeType());
InputStream is = okmDocument.getContent(token, BASE + "/pi.txt", false); InputStream is = okmDocument.getContent(token, BASE + "/pi.txt", false);
String remContent = IOUtils.toString(is); String remContent = IOUtils.toString(is);
assertEquals(locContent, remContent); assertEquals(locContent, remContent);
 End of changes. 1 change blocks. 
1 lines changed or deleted 1 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)