| java.lang.Object org.ow2.easybeans.tests.deploymentdesc.TestAppException
TestAppException | public class TestAppException (Code) | | Verifies if the container can set the application exception defined by
deployment descriptor.
author: Gisele Pinheiro Souza author: Eduardo Studzinski Estima de Castro |
Field Summary | |
final public static String | DB_NAME The database used during the tests. |
Method Summary | |
protected void | deleteTable(String dbName) Deletes the table in the database. | public void | setup() Creates the stateful bean used during the tests. | public void | testAppExceptionWithRollback() Verifies if the definition if an application exception(with rollback =
true) in the deployment descriptor works properly. | public void | testAppExceptionWithRollbackDefault() Verifies if the definition if an application exception(with the dafault rollback
value) in the deployment descriptor works properly. | public void | testAppExceptionWithRollbackOverride() Verifies if the definition if an application exception overrided in a
deployment descriptor works properly. | public void | testAppExceptionWithoutRollback() Verifies if the definition if an application exception(with rollback =
false) in the deployment descriptor works properly. | protected void | verifyTable(String database) Verifies if the table was created in the database. |
DB_NAME | final public static String DB_NAME(Code) | | The database used during the tests.
|
deleteTable | protected void deleteTable(String dbName)(Code) | | Deletes the table in the database.
Parameters: dbName - the database name in the registry. |
setup | public void setup() throws Exception(Code) | | Creates the stateful bean used during the tests.
throws: Exception - if an error occurs during the lookup. |
testAppExceptionWithRollback | public void testAppExceptionWithRollback() throws Exception(Code) | | Verifies if the definition if an application exception(with rollback =
true) in the deployment descriptor works properly. When an application
exception with rollback = true occurs, the container must mark the
transaction for rollback. Also, the container must re-throw the
exception.
throws: Exception - if some error occurs during the tests. |
testAppExceptionWithRollbackDefault | public void testAppExceptionWithRollbackDefault() throws Exception(Code) | | Verifies if the definition if an application exception(with the dafault rollback
value) in the deployment descriptor works properly. When an application
exception with rollback defult value(false) occurs, the container must not mark the
transaction for rollback. Also, the container must re-throw the
exception.
throws: Exception - if some error occurs during the tests. |
testAppExceptionWithRollbackOverride | public void testAppExceptionWithRollbackOverride() throws Exception(Code) | | Verifies if the definition if an application exception overrided in a
deployment descriptor works properly. The annotation defines the
rollback as true, however the deployment descriptor defines
the transaction attribute as false. The deployment descriptor must
override the annotation value for the rollback. When an application
exception with rollback = false occurs, the container must not mark the
transaction for rollback. Also, the container must re-throw the
exception.
throws: Exception - if some error occurs during the tests. |
testAppExceptionWithoutRollback | public void testAppExceptionWithoutRollback() throws Exception(Code) | | Verifies if the definition if an application exception(with rollback =
false) in the deployment descriptor works properly. When an application
exception with rollback = false occurs, the container must not mark the
transaction for rollback. Also, the container must re-throw the
exception.
throws: Exception - if some error occurs during the tests. |
|
|