org.objectweb.jonas.jtests.clients.distribution
Class F_Cluster

java.lang.Object
  |
  +--junit.framework.Assert
        |
        +--junit.framework.TestCase
              |
              +--org.objectweb.jonas.jtests.util.JTestCase
                    |
                    +--org.objectweb.jonas.jtests.clients.distribution.F_Cluster
All Implemented Interfaces:
junit.framework.Test

public class F_Cluster
extends JTestCase


Field Summary
static int CREATE
           
protected static IdentityHome home1
           
protected static IdentityHome home2
           
protected static IdentityHome home3
           
static int READ
           
static int REMOVE
           
static java.lang.Exception threadError
           
static int WRITE
           
 
Fields inherited from class org.objectweb.jonas.jtests.util.JTestCase
ictx, isInit, jonasName, msgerror, testtorun, utx
 
Constructor Summary
F_Cluster(java.lang.String name)
           
 
Method Summary
static void main(java.lang.String[] args)
           
protected  void setUp()
          common setUp routine, used for every test.
static junit.framework.Test suite()
           
protected  void tearDown()
           
 void test2Home()
          Test with 2 homes (no parallellism)
 void testIso1()
          Test isolation case 1: 2 parallell transactions writing the same instance.
 void testIso2()
          Test isolation case 2: 2 parallell transactions writing the same instance.
 void testSingle()
          Basic Test to see if all works with a single bean (it should!)
 
Methods inherited from class org.objectweb.jonas.jtests.util.JTestCase
debug, getDBEnv, random, sleep, testEmpty, unloadBeans, useBeans
 
Methods inherited from class junit.framework.TestCase
countTestCases, createResult, getName, name, run, run, runBare, runTest, setName, toString
 
Methods inherited from class junit.framework.Assert
assert, assert, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertNotNull, assertNotNull, assertNull, assertNull, assertSame, assertSame, assertTrue, assertTrue, fail, fail
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

home1

protected static IdentityHome home1

home2

protected static IdentityHome home2

home3

protected static IdentityHome home3

threadError

public static java.lang.Exception threadError

READ

public static final int READ

WRITE

public static final int WRITE

CREATE

public static final int CREATE

REMOVE

public static final int REMOVE
Constructor Detail

F_Cluster

public F_Cluster(java.lang.String name)
Method Detail

setUp

protected void setUp()
Description copied from class: JTestCase
common setUp routine, used for every test.
Overrides:
setUp in class JTestCase

tearDown

protected void tearDown()
                 throws java.lang.Exception
Overrides:
tearDown in class JTestCase

testSingle

public void testSingle()
                throws java.lang.Exception
Basic Test to see if all works with a single bean (it should!) Pre-requisite: the table has been initialized first with some well-known values (name1, ...)

test2Home

public void test2Home()
               throws java.lang.Exception
Test with 2 homes (no parallellism)

testIso1

public void testIso1()
              throws java.lang.Exception
Test isolation case 1: 2 parallell transactions writing the same instance. -> depending on database, several different cases may happen.

testIso2

public void testIso2()
              throws java.lang.Exception
Test isolation case 2: 2 parallell transactions writing the same instance. -> depending on database, several different cases may happen.

suite

public static junit.framework.Test suite()

main

public static void main(java.lang.String[] args)