mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-07-31 17:39:05 +00:00
Thumbnail Service: support for asyn creation of thumbnails (unit test's included)
git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@9428 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -0,0 +1,31 @@
|
||||
function testCreateThumbnail()
|
||||
{
|
||||
// Create a thumbnail
|
||||
var thumbnail = jpgOrig.createThumbnail("medium");
|
||||
test.assertNotNull(thumbnail);
|
||||
|
||||
// Create async thumbnail
|
||||
// var thumbnail2 = gifOrig.createThumbnail("medium", true);
|
||||
// test.assertNull(thumbnail2);
|
||||
|
||||
// Try and get the created thumbnail
|
||||
// var count = 0;
|
||||
// while (true)
|
||||
// {
|
||||
// thumbnail2 = gifOrig.getThumbnail("medium");
|
||||
|
||||
// if (thumbnail2 != null)
|
||||
// {
|
||||
// break;
|
||||
// }
|
||||
//else if (count > 1000)
|
||||
//{
|
||||
// test.fail("Async thumbanil wasn't created");
|
||||
//}
|
||||
|
||||
// count++;
|
||||
// }
|
||||
}
|
||||
|
||||
// Execute the tests
|
||||
testCreateThumbnail();
|
Reference in New Issue
Block a user