org.exoplatform.jcr.benchmark.ext.asyncrep
Class AsyncTestBase

java.lang.Object
  extended by org.exoplatform.jcr.benchmark.ext.asyncrep.AsyncTestBase
Direct Known Subclasses:
ConflictSunchronizeMoveTest, ConflictSynchronizeTest, ConflictVersionTest, ExtendedVersionTest, LoadFilesAndSynchronizeTest, SimpleVersionTest

public abstract class AsyncTestBase
extends java.lang.Object

Created by The eXo Platform SAS.
Date:

Version:
$Id: AsynctestBase.java 111 2008-11-11 11:11:11Z serg $
Author:
Karpenko Sergiy

Field Summary
 java.io.File content
          File content generated in doPrepare();
 int COUNT_I
          Default saves count.
 int COUNT_J
          Default file per save count.
 int fc
          File per save Count.
protected static org.exoplatform.services.log.Log log
           
 int sc
          Saves Count.
 
Constructor Summary
AsyncTestBase()
           
 
Method Summary
static java.io.File createBLOBfile(int sizeKb)
          Create File with random content and fixed size.
 void doFinish(com.sun.japex.TestCase tc, AsyncTestContext context)
          Do finish operations.
 void doPrepare(com.sun.japex.TestCase tc, AsyncTestContext context)
          Do test prepare.
abstract  void doRun(com.sun.japex.TestCase tc, AsyncTestContext context)
          Run test.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

log

protected static org.exoplatform.services.log.Log log

COUNT_I

public final int COUNT_I
Default saves count.

See Also:
Constant Field Values

COUNT_J

public final int COUNT_J
Default file per save count.

See Also:
Constant Field Values

content

public java.io.File content
File content generated in doPrepare();


sc

public int sc
Saves Count.


fc

public int fc
File per save Count.

Constructor Detail

AsyncTestBase

public AsyncTestBase()
Method Detail

doPrepare

public void doPrepare(com.sun.japex.TestCase tc,
                      AsyncTestContext context)
               throws java.lang.Exception
Do test prepare.

Parameters:
tc - - TestCase.
context - - AsyncTestContext.
Throws:
java.lang.Exception - - internal Exception.

doFinish

public void doFinish(com.sun.japex.TestCase tc,
                     AsyncTestContext context)
              throws java.lang.Exception
Do finish operations.

Parameters:
tc - - TestCase.
context - - AsyncTestContext.
Throws:
java.lang.Exception - - internal Exception.

doRun

public abstract void doRun(com.sun.japex.TestCase tc,
                           AsyncTestContext context)
                    throws java.lang.Exception
Run test.

Parameters:
tc - - TestCase.
context - - AsyncTestContext.
Throws:
java.lang.Exception - - internal Exception.

createBLOBfile

public static java.io.File createBLOBfile(int sizeKb)
                                   throws java.io.IOException
Create File with random content and fixed size.

Parameters:
sizeKb - - file size in Kb.
Returns:
File
Throws:
java.io.IOException - - if IO exception occurs.


Copyright © 2010 eXo Platform SAS. All Rights Reserved.