You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tomee.apache.org by an...@apache.org on 2014/07/07 21:07:53 UTC
svn commit: r1608563 [28/38] - in /tomee/tomee/branches/tomee-1.7.x/itests:
failover-ejb/src/main/java/org/apache/openejb/itest/failover/ejb/
failover/src/main/java/org/apache/openejb/itest/failover/
failover/src/main/java/org/apache/openejb/server/con...
Modified: tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/entity/cmr/OneToOneComplexPkTests.java
URL: http://svn.apache.org/viewvc/tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/entity/cmr/OneToOneComplexPkTests.java?rev=1608563&r1=1608562&r2=1608563&view=diff
==============================================================================
--- tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/entity/cmr/OneToOneComplexPkTests.java (original)
+++ tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/entity/cmr/OneToOneComplexPkTests.java Mon Jul 7 19:07:41 2014
@@ -54,9 +54,9 @@ public class OneToOneComplexPkTests exte
resetDB();
beginTransaction();
try {
- PersonLocal person = findPerson(1);
+ final PersonLocal person = findPerson(1);
assertNotNull("person is null", person);
- LicenseLocal license = person.getLicense();
+ final LicenseLocal license = person.getLicense();
assertNotNull("license is null", license);
assertEquals(new Integer(11), license.getId());
assertEquals("value11", license.getNumber());
@@ -69,8 +69,8 @@ public class OneToOneComplexPkTests exte
resetDB();
beginTransaction();
try {
- LicenseLocal license = findLicense(11);
- PersonLocal person = license.getPerson();
+ final LicenseLocal license = findLicense(11);
+ final PersonLocal person = license.getPerson();
assertNotNull(person);
assertEquals(new Integer(1), person.getId());
assertEquals("value1", person.getName());
@@ -83,7 +83,7 @@ public class OneToOneComplexPkTests exte
resetDB();
beginTransaction();
try {
- PersonLocal person = findPerson(1);
+ final PersonLocal person = findPerson(1);
person.setLicense(null);
} finally {
completeTransaction();
@@ -96,7 +96,7 @@ public class OneToOneComplexPkTests exte
resetDB();
beginTransaction();
try {
- LicenseLocal license = findLicense(11);
+ final LicenseLocal license = findLicense(11);
license.setPerson(null);
} finally {
completeTransaction();
@@ -109,8 +109,8 @@ public class OneToOneComplexPkTests exte
resetDB();
beginTransaction();
try {
- PersonLocal person = findPerson(2);
- LicenseLocal license = createLicense(22);
+ final PersonLocal person = findPerson(2);
+ final LicenseLocal license = createLicense(22);
person.setLicense(license);
} finally {
completeTransaction();
@@ -123,8 +123,8 @@ public class OneToOneComplexPkTests exte
resetDB();
beginTransaction();
try {
- PersonLocal person = findPerson(2);
- LicenseLocal license = createLicense(22);
+ final PersonLocal person = findPerson(2);
+ final LicenseLocal license = createLicense(22);
license.setPerson(person);
} finally {
completeTransaction();
@@ -137,8 +137,8 @@ public class OneToOneComplexPkTests exte
resetDB();
beginTransaction();
try {
- PersonLocal person = findPerson(2);
- LicenseLocal license = findLicense(11);
+ final PersonLocal person = findPerson(2);
+ final LicenseLocal license = findLicense(11);
person.setLicense(license);
} finally {
completeTransaction();
@@ -151,8 +151,8 @@ public class OneToOneComplexPkTests exte
resetDB();
beginTransaction();
try {
- PersonLocal person = createPerson(3);
- LicenseLocal license = findLicense(11);
+ final PersonLocal person = createPerson(3);
+ final LicenseLocal license = findLicense(11);
license.setPerson(person);
} finally {
completeTransaction();
@@ -164,8 +164,8 @@ public class OneToOneComplexPkTests exte
resetDB();
beginTransaction();
try {
- PersonLocal person = findPerson(1);
- LicenseLocal license = createLicense(22);
+ final PersonLocal person = findPerson(1);
+ final LicenseLocal license = createLicense(22);
license.setPerson(person);
} finally {
completeTransaction();
@@ -177,14 +177,14 @@ public class OneToOneComplexPkTests exte
resetDB();
beginTransaction();
try {
- PersonLocal person = findPerson(1);
+ final PersonLocal person = findPerson(1);
person.remove();
} finally {
completeTransaction();
}
- Connection c = ds.getConnection();
- Statement s = c.createStatement();
+ final Connection c = ds.getConnection();
+ final Statement s = c.createStatement();
ResultSet rs = s.executeQuery("SELECT COUNT(*) FROM ComplexLicense");
assertTrue(rs.next());
assertEquals(1, rs.getInt(1));
@@ -201,15 +201,15 @@ public class OneToOneComplexPkTests exte
resetDB();
beginTransaction();
try {
- LicenseLocal license = findLicense(11);
+ final LicenseLocal license = findLicense(11);
license.remove();
} finally {
completeTransaction();
}
- Connection c = ds.getConnection();
- Statement s = c.createStatement();
- ResultSet rs = s.executeQuery("SELECT COUNT(*) FROM ComplexPerson WHERE id = 1");
+ final Connection c = ds.getConnection();
+ final Statement s = c.createStatement();
+ final ResultSet rs = s.executeQuery("SELECT COUNT(*) FROM ComplexPerson WHERE id = 1");
assertTrue(rs.next());
assertEquals(0, rs.getInt(1));
close(rs);
@@ -222,9 +222,9 @@ public class OneToOneComplexPkTests exte
resetDB();
beginTransaction();
try {
- LicenseLocal license = findLicense(11);
+ final LicenseLocal license = findLicense(11);
- Integer field3 = license.getPoints();
+ final Integer field3 = license.getPoints();
assertEquals(license.getPerson().getPrimaryKey(), field3);
} finally {
completeTransaction();
@@ -236,11 +236,11 @@ public class OneToOneComplexPkTests exte
resetDB();
beginTransaction();
try {
- LicenseLocal license = findLicense(11);
+ final LicenseLocal license = findLicense(11);
license.setPoints(new Integer(2));
- PersonLocal person = license.getPerson();
+ final PersonLocal person = license.getPerson();
assertEquals(new Integer(2), person.getId());
assertEquals("value2", person.getName());
} finally {
@@ -248,26 +248,26 @@ public class OneToOneComplexPkTests exte
}
}
- private PersonLocal createPerson(int personId) throws CreateException {
- PersonLocal person = personLocalHome.create(new PersonPk(personId, "value" + personId));
+ private PersonLocal createPerson(final int personId) throws CreateException {
+ final PersonLocal person = personLocalHome.create(new PersonPk(personId, "value" + personId));
return person;
}
- private PersonLocal findPerson(int personId) throws FinderException {
+ private PersonLocal findPerson(final int personId) throws FinderException {
return personLocalHome.findByPrimaryKey(new PersonPk(personId, "value" + personId));
}
- private LicenseLocal createLicense(int licenseId) throws CreateException {
- LicenseLocal license = licenseLocalHome.create(new LicensePk(licenseId, "value" + licenseId));
+ private LicenseLocal createLicense(final int licenseId) throws CreateException {
+ final LicenseLocal license = licenseLocalHome.create(new LicensePk(licenseId, "value" + licenseId));
return license;
}
- private LicenseLocal findLicense(int licenseId) throws FinderException {
+ private LicenseLocal findLicense(final int licenseId) throws FinderException {
return licenseLocalHome.findByPrimaryKey(new LicensePk(licenseId, "value" + licenseId));
}
- private void assertLinked(int personId, int licenseId) throws Exception {
- Connection c = ds.getConnection();
- Statement s = c.createStatement();
+ private void assertLinked(final int personId, final int licenseId) throws Exception {
+ final Connection c = ds.getConnection();
+ final Statement s = c.createStatement();
ResultSet rs = s.executeQuery("SELECT name FROM ComplexPerson WHERE id = " + personId);
assertTrue(rs.next());
assertEquals("value" + personId, rs.getString("name"));
@@ -282,10 +282,10 @@ public class OneToOneComplexPkTests exte
close(c);
}
- private void assertUnlinked(int personId) throws Exception {
- Connection c = ds.getConnection();
- Statement s = c.createStatement();
- ResultSet rs = s.executeQuery("SELECT COUNT(*) FROM ComplexLicense WHERE person_id = " + personId);
+ private void assertUnlinked(final int personId) throws Exception {
+ final Connection c = ds.getConnection();
+ final Statement s = c.createStatement();
+ final ResultSet rs = s.executeQuery("SELECT COUNT(*) FROM ComplexLicense WHERE person_id = " + personId);
assertTrue(rs.next());
assertEquals(0, rs.getInt(1));
close(rs);
@@ -295,28 +295,28 @@ public class OneToOneComplexPkTests exte
private void resetDB() throws Exception {
- Connection connection = ds.getConnection();
+ final Connection connection = ds.getConnection();
Statement statement = null;
try {
statement = connection.createStatement();
try {
statement.execute("DELETE FROM ComplexPerson");
- } catch (SQLException ignored) {
+ } catch (final SQLException ignored) {
}
try {
statement.execute("DELETE FROM ComplexLicense");
- } catch (SQLException ignored) {
+ } catch (final SQLException ignored) {
}
} finally {
close(statement);
close(connection);
}
- PersonLocal person1 = createPerson(1);
+ final PersonLocal person1 = createPerson(1);
createPerson(2);
- LicenseLocal license = createLicense(11);
+ final LicenseLocal license = createLicense(11);
license.setPerson(person1);
}
Modified: tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/entity/cmr/OneToOneTests.java
URL: http://svn.apache.org/viewvc/tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/entity/cmr/OneToOneTests.java?rev=1608563&r1=1608562&r2=1608563&view=diff
==============================================================================
--- tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/entity/cmr/OneToOneTests.java (original)
+++ tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/entity/cmr/OneToOneTests.java Mon Jul 7 19:07:41 2014
@@ -52,9 +52,9 @@ public class OneToOneTests extends Abstr
resetDB();
beginTransaction();
try {
- PersonLocal person = findPerson(1);
+ final PersonLocal person = findPerson(1);
assertNotNull("person is null", person);
- LicenseLocal license = person.getLicense();
+ final LicenseLocal license = person.getLicense();
assertNotNull("license is null", license);
assertEquals(new Integer(11), license.getId());
assertEquals("value11", license.getNumber());
@@ -67,8 +67,8 @@ public class OneToOneTests extends Abstr
resetDB();
beginTransaction();
try {
- LicenseLocal license = findLicense(11);
- PersonLocal person = license.getPerson();
+ final LicenseLocal license = findLicense(11);
+ final PersonLocal person = license.getPerson();
assertNotNull(person);
assertEquals(new Integer(1), person.getId());
assertEquals("value1", person.getName());
@@ -81,7 +81,7 @@ public class OneToOneTests extends Abstr
resetDB();
beginTransaction();
try {
- PersonLocal person = findPerson(1);
+ final PersonLocal person = findPerson(1);
person.setLicense(null);
} finally {
completeTransaction();
@@ -94,7 +94,7 @@ public class OneToOneTests extends Abstr
resetDB();
beginTransaction();
try {
- LicenseLocal license = findLicense(11);
+ final LicenseLocal license = findLicense(11);
license.setPerson(null);
} finally {
completeTransaction();
@@ -107,8 +107,8 @@ public class OneToOneTests extends Abstr
resetDB();
beginTransaction();
try {
- PersonLocal person = findPerson(2);
- LicenseLocal license = createLicense(22);
+ final PersonLocal person = findPerson(2);
+ final LicenseLocal license = createLicense(22);
person.setLicense(license);
} finally {
completeTransaction();
@@ -121,8 +121,8 @@ public class OneToOneTests extends Abstr
resetDB();
beginTransaction();
try {
- PersonLocal person = findPerson(2);
- LicenseLocal license = createLicense(22);
+ final PersonLocal person = findPerson(2);
+ final LicenseLocal license = createLicense(22);
license.setPerson(person);
} finally {
completeTransaction();
@@ -135,8 +135,8 @@ public class OneToOneTests extends Abstr
resetDB();
beginTransaction();
try {
- PersonLocal person = findPerson(2);
- LicenseLocal license = findLicense(11);
+ final PersonLocal person = findPerson(2);
+ final LicenseLocal license = findLicense(11);
person.setLicense(license);
} finally {
completeTransaction();
@@ -149,8 +149,8 @@ public class OneToOneTests extends Abstr
resetDB();
beginTransaction();
try {
- PersonLocal person = createPerson(3);
- LicenseLocal license = findLicense(11);
+ final PersonLocal person = createPerson(3);
+ final LicenseLocal license = findLicense(11);
license.setPerson(person);
} finally {
completeTransaction();
@@ -162,8 +162,8 @@ public class OneToOneTests extends Abstr
resetDB();
beginTransaction();
try {
- PersonLocal person = findPerson(1);
- LicenseLocal license = createLicense(22);
+ final PersonLocal person = findPerson(1);
+ final LicenseLocal license = createLicense(22);
license.setPerson(person);
} finally {
completeTransaction();
@@ -175,14 +175,14 @@ public class OneToOneTests extends Abstr
resetDB();
beginTransaction();
try {
- PersonLocal person = findPerson(1);
+ final PersonLocal person = findPerson(1);
person.remove();
} finally {
completeTransaction();
}
- Connection c = ds.getConnection();
- Statement s = c.createStatement();
+ final Connection c = ds.getConnection();
+ final Statement s = c.createStatement();
ResultSet rs = s.executeQuery("SELECT COUNT(*) FROM License");
assertTrue(rs.next());
assertEquals(1, rs.getInt(1));
@@ -199,15 +199,15 @@ public class OneToOneTests extends Abstr
resetDB();
beginTransaction();
try {
- LicenseLocal license = findLicense(11);
+ final LicenseLocal license = findLicense(11);
license.remove();
} finally {
completeTransaction();
}
- Connection c = ds.getConnection();
- Statement s = c.createStatement();
- ResultSet rs = s.executeQuery("SELECT COUNT(*) FROM Person WHERE id = 1");
+ final Connection c = ds.getConnection();
+ final Statement s = c.createStatement();
+ final ResultSet rs = s.executeQuery("SELECT COUNT(*) FROM Person WHERE id = 1");
assertTrue(rs.next());
assertEquals(0, rs.getInt(1));
close(rs);
@@ -220,9 +220,9 @@ public class OneToOneTests extends Abstr
resetDB();
beginTransaction();
try {
- LicenseLocal license = findLicense(11);
+ final LicenseLocal license = findLicense(11);
- Integer field3 = license.getPoints();
+ final Integer field3 = license.getPoints();
assertEquals(license.getPerson().getPrimaryKey(), field3);
} finally {
completeTransaction();
@@ -234,11 +234,11 @@ public class OneToOneTests extends Abstr
resetDB();
beginTransaction();
try {
- LicenseLocal license = findLicense(11);
+ final LicenseLocal license = findLicense(11);
license.setPoints(new Integer(2));
- PersonLocal person = license.getPerson();
+ final PersonLocal person = license.getPerson();
assertEquals(new Integer(2), person.getId());
assertEquals("value2", person.getName());
} finally {
@@ -246,29 +246,29 @@ public class OneToOneTests extends Abstr
}
}
- private PersonLocal createPerson(int personId) throws CreateException {
- PersonLocal person = personLocalHome.create(personId);
+ private PersonLocal createPerson(final int personId) throws CreateException {
+ final PersonLocal person = personLocalHome.create(personId);
person.setName("value" + personId);
return person;
}
- private PersonLocal findPerson(int personId) throws FinderException {
+ private PersonLocal findPerson(final int personId) throws FinderException {
return personLocalHome.findByPrimaryKey(personId);
}
- private LicenseLocal createLicense(int licenseId) throws CreateException {
- LicenseLocal license = licenseLocalHome.create(licenseId);
+ private LicenseLocal createLicense(final int licenseId) throws CreateException {
+ final LicenseLocal license = licenseLocalHome.create(licenseId);
license.setNumber("value" + licenseId);
return license;
}
- private LicenseLocal findLicense(int licenseId) throws FinderException {
+ private LicenseLocal findLicense(final int licenseId) throws FinderException {
return licenseLocalHome.findByPrimaryKey(licenseId);
}
- private void assertLinked(int personId, int licenseId) throws Exception {
- Connection c = ds.getConnection();
- Statement s = c.createStatement();
+ private void assertLinked(final int personId, final int licenseId) throws Exception {
+ final Connection c = ds.getConnection();
+ final Statement s = c.createStatement();
ResultSet rs = s.executeQuery("SELECT name FROM Person WHERE id = " + personId);
assertTrue(rs.next());
assertEquals("value" + personId, rs.getString("name"));
@@ -283,10 +283,10 @@ public class OneToOneTests extends Abstr
close(c);
}
- private void assertUnlinked(int personId) throws Exception {
- Connection c = ds.getConnection();
- Statement s = c.createStatement();
- ResultSet rs = s.executeQuery("SELECT COUNT(*) FROM License WHERE person_id = " + personId);
+ private void assertUnlinked(final int personId) throws Exception {
+ final Connection c = ds.getConnection();
+ final Statement s = c.createStatement();
+ final ResultSet rs = s.executeQuery("SELECT COUNT(*) FROM License WHERE person_id = " + personId);
assertTrue(rs.next());
assertEquals(0, rs.getInt(1));
close(rs);
@@ -296,28 +296,28 @@ public class OneToOneTests extends Abstr
private void resetDB() throws Exception {
- Connection connection = ds.getConnection();
+ final Connection connection = ds.getConnection();
Statement statement = null;
try {
statement = connection.createStatement();
try {
statement.execute("DELETE FROM Person");
- } catch (SQLException ignored) {
+ } catch (final SQLException ignored) {
}
try {
statement.execute("DELETE FROM License");
- } catch (SQLException ignored) {
+ } catch (final SQLException ignored) {
}
} finally {
close(statement);
close(connection);
}
- PersonLocal person1 = createPerson(1);
+ final PersonLocal person1 = createPerson(1);
createPerson(2);
- LicenseLocal license = createLicense(11);
+ final LicenseLocal license = createLicense(11);
license.setPerson(person1);
}
Modified: tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/mdb/BasicMdbTests.java
URL: http://svn.apache.org/viewvc/tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/mdb/BasicMdbTests.java?rev=1608563&r1=1608562&r2=1608563&view=diff
==============================================================================
--- tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/mdb/BasicMdbTests.java (original)
+++ tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/mdb/BasicMdbTests.java Mon Jul 7 19:07:41 2014
@@ -32,7 +32,7 @@ public class BasicMdbTests extends MdbTe
protected void setUp() throws Exception {
super.setUp();
- Destination destination = (Destination) initialContext.lookup("client/tests/messagedriven/mdb/BasicMdb");
+ final Destination destination = (Destination) initialContext.lookup("client/tests/messagedriven/mdb/BasicMdb");
basicMdbObject = MdbProxy.newProxyInstance(BasicMdbObject.class, connectionFactory, destination);
}
@@ -47,10 +47,10 @@ public class BasicMdbTests extends MdbTe
//
public void test01_businessMethod(){
try{
- String expected = "Success";
- String actual = basicMdbObject.businessMethod("sseccuS");
+ final String expected = "Success";
+ final String actual = basicMdbObject.businessMethod("sseccuS");
assertEquals(expected, actual);
- } catch (Exception e){
+ } catch (final Exception e){
e.printStackTrace();
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
@@ -63,10 +63,10 @@ public class BasicMdbTests extends MdbTe
public void Xtest02_throwApplicationException(){
try{
basicMdbObject.throwApplicationException();
- } catch (org.apache.openejb.test.ApplicationException e){
+ } catch (final org.apache.openejb.test.ApplicationException e){
//Good. This is the correct behaviour
return;
- } catch (Throwable e){
+ } catch (final Throwable e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
fail("An ApplicationException should have been thrown.");
@@ -78,10 +78,10 @@ public class BasicMdbTests extends MdbTe
*/
public void test03_invokeAfterApplicationException(){
try{
- String expected = "Success";
- String actual = basicMdbObject.businessMethod("sseccuS");
+ final String expected = "Success";
+ final String actual = basicMdbObject.businessMethod("sseccuS");
assertEquals(expected, actual);
- } catch (Throwable e){
+ } catch (final Throwable e){
e.printStackTrace();
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
@@ -90,13 +90,13 @@ public class BasicMdbTests extends MdbTe
public void Xtest04_throwSystemException(){
try{
basicMdbObject.throwSystemException_NullPointer();
- } catch (Exception e){
+ } catch (final Exception e){
//Good, so far.
- Throwable n = e.getCause();
+ final Throwable n = e.getCause();
assertNotNull("Nested exception should not be is null", n );
assertTrue("Nested exception should be an instance of NullPointerException, but exception is "+n.getClass().getName(), (n instanceof NullPointerException));
return;
- } catch (Throwable e){
+ } catch (final Throwable e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
fail("A NullPointerException should have been thrown.");
@@ -112,9 +112,9 @@ public class BasicMdbTests extends MdbTe
try{
basicMdbObject.businessMethod("This refernce is invalid");
fail("A java.rmi.NoSuchObjectException should have been thrown.");
- } catch (Exception e){
+ } catch (final Exception e){
// Good.
- } catch (Throwable e){
+ } catch (final Throwable e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
Modified: tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/mdb/BmtMdbAllowedOperationsTests.java
URL: http://svn.apache.org/viewvc/tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/mdb/BmtMdbAllowedOperationsTests.java?rev=1608563&r1=1608562&r2=1608563&view=diff
==============================================================================
--- tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/mdb/BmtMdbAllowedOperationsTests.java (original)
+++ tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/mdb/BmtMdbAllowedOperationsTests.java Mon Jul 7 19:07:41 2014
@@ -71,7 +71,7 @@ public class BmtMdbAllowedOperationsTest
protected void setUp() throws Exception {
super.setUp();
- Destination destination = (Destination) initialContext.lookup("Basic BMT Mdb Bean");
+ final Destination destination = (Destination) initialContext.lookup("Basic BMT Mdb Bean");
basicMdbObject = MdbProxy.newProxyInstance(BasicMdbObject.class, connectionFactory, destination);
basicMdbObject.businessMethod("foo");
}
@@ -98,16 +98,16 @@ public class BmtMdbAllowedOperationsTest
*/
public void test01_setSessionContext(){
try {
- OperationsPolicy policy = new OperationsPolicy();
+ final OperationsPolicy policy = new OperationsPolicy();
policy.allow( OperationsPolicy.Context_lookup);
policy.allow( OperationsPolicy.JNDI_access_to_java_comp_env );
- Object expected = policy;
- Object actual = basicMdbObject.getAllowedOperationsReport("setMessageDrivenContext");
+ final Object expected = policy;
+ final Object actual = basicMdbObject.getAllowedOperationsReport("setMessageDrivenContext");
assertNotNull("The OperationsPolicy is null", actual );
assertEquals( expected, actual );
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -126,17 +126,17 @@ public class BmtMdbAllowedOperationsTest
*/
public void test02_ejbCreate() {
try {
- OperationsPolicy policy = new OperationsPolicy();
+ final OperationsPolicy policy = new OperationsPolicy();
policy.allow( OperationsPolicy.Context_lookup );
policy.allow( OperationsPolicy.Context_getUserTransaction );
policy.allow( OperationsPolicy.JNDI_access_to_java_comp_env );
- Object expected = policy;
- Object actual = basicMdbObject.getAllowedOperationsReport("ejbCreate");
+ final Object expected = policy;
+ final Object actual = basicMdbObject.getAllowedOperationsReport("ejbCreate");
assertNotNull("The OperationsPolicy is null", actual );
assertEquals( expected, actual );
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -157,18 +157,18 @@ public class BmtMdbAllowedOperationsTest
public void TODO_test03_ejbRemove(){
try {
/* TO DO: This test needs unique functionality to work */
- OperationsPolicy policy = new OperationsPolicy();
+ final OperationsPolicy policy = new OperationsPolicy();
policy.allow( OperationsPolicy.Context_getEJBHome );
policy.allow( OperationsPolicy.Context_getEJBObject );
policy.allow( OperationsPolicy.Context_getUserTransaction );
policy.allow( OperationsPolicy.JNDI_access_to_java_comp_env );
- Object expected = policy;
- Object actual = basicMdbObject.getAllowedOperationsReport("ejbRemove");
+ final Object expected = policy;
+ final Object actual = basicMdbObject.getAllowedOperationsReport("ejbRemove");
assertNotNull("The OperationsPolicy is null", actual );
assertEquals( expected, actual );
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -192,19 +192,19 @@ public class BmtMdbAllowedOperationsTest
*/
public void test04_businessMethod(){
try {
- OperationsPolicy policy = new OperationsPolicy();
+ final OperationsPolicy policy = new OperationsPolicy();
policy.allow( OperationsPolicy.Context_getUserTransaction );
policy.allow( OperationsPolicy.Context_getCallerPrincipal );
policy.allow( OperationsPolicy.Context_isCallerInRole );
policy.allow( OperationsPolicy.Context_lookup );
policy.allow( OperationsPolicy.JNDI_access_to_java_comp_env );
- Object expected = policy;
- Object actual = basicMdbObject.getAllowedOperationsReport("businessMethod");
+ final Object expected = policy;
+ final Object actual = basicMdbObject.getAllowedOperationsReport("businessMethod");
assertNotNull("The OperationsPolicy is null", actual );
assertEquals( expected, actual );
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
Modified: tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/mdb/MdbAllowedOperationsTests.java
URL: http://svn.apache.org/viewvc/tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/mdb/MdbAllowedOperationsTests.java?rev=1608563&r1=1608562&r2=1608563&view=diff
==============================================================================
--- tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/mdb/MdbAllowedOperationsTests.java (original)
+++ tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/mdb/MdbAllowedOperationsTests.java Mon Jul 7 19:07:41 2014
@@ -71,7 +71,7 @@ public class MdbAllowedOperationsTests e
protected void setUp() throws Exception {
super.setUp();
- Destination destination = (Destination) initialContext.lookup("client/tests/messagedriven/mdb/BasicMdb");
+ final Destination destination = (Destination) initialContext.lookup("client/tests/messagedriven/mdb/BasicMdb");
basicMdbObject = MdbProxy.newProxyInstance(BasicMdbObject.class, connectionFactory, destination);
basicMdbObject.businessMethod("foo");
}
@@ -97,16 +97,16 @@ public class MdbAllowedOperationsTests e
*/
public void test01_setSessionContext(){
try {
- OperationsPolicy policy = new OperationsPolicy();
+ final OperationsPolicy policy = new OperationsPolicy();
policy.allow( OperationsPolicy.Context_lookup);
policy.allow( OperationsPolicy.JNDI_access_to_java_comp_env );
- Object expected = policy;
- Object actual = basicMdbObject.getAllowedOperationsReport("setMessageDrivenContext");
+ final Object expected = policy;
+ final Object actual = basicMdbObject.getAllowedOperationsReport("setMessageDrivenContext");
assertNotNull("The OperationsPolicy is null", actual );
assertEquals( expected, actual );
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -124,16 +124,16 @@ public class MdbAllowedOperationsTests e
*/
public void test02_ejbCreate() {
try {
- OperationsPolicy policy = new OperationsPolicy();
+ final OperationsPolicy policy = new OperationsPolicy();
policy.allow( OperationsPolicy.Context_lookup);
policy.allow( OperationsPolicy.JNDI_access_to_java_comp_env );
- Object expected = policy;
- Object actual = basicMdbObject.getAllowedOperationsReport("ejbCreate");
+ final Object expected = policy;
+ final Object actual = basicMdbObject.getAllowedOperationsReport("ejbCreate");
assertNotNull("The OperationsPolicy is null", actual );
assertEquals( expected, actual );
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -152,17 +152,17 @@ public class MdbAllowedOperationsTests e
public void TODO_test03_ejbRemove(){
try {
/* TO DO: This test needs unique functionality to work */
- OperationsPolicy policy = new OperationsPolicy();
+ final OperationsPolicy policy = new OperationsPolicy();
policy.allow( OperationsPolicy.Context_getEJBHome );
policy.allow( OperationsPolicy.Context_getEJBObject );
policy.allow( OperationsPolicy.JNDI_access_to_java_comp_env );
- Object expected = policy;
- Object actual = basicMdbObject.getAllowedOperationsReport("ejbRemove");
+ final Object expected = policy;
+ final Object actual = basicMdbObject.getAllowedOperationsReport("ejbRemove");
assertNotNull("The OperationsPolicy is null", actual );
assertEquals( expected, actual );
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -187,7 +187,7 @@ public class MdbAllowedOperationsTests e
*/
public void TODO_test04_businessMethod(){
try {
- OperationsPolicy policy = new OperationsPolicy();
+ final OperationsPolicy policy = new OperationsPolicy();
policy.allow( OperationsPolicy.Context_getRollbackOnly );
// policy.allow( OperationsPolicy.Context_setRollbackOnly );
policy.allow( OperationsPolicy.Context_getCallerPrincipal );
@@ -195,12 +195,12 @@ public class MdbAllowedOperationsTests e
policy.allow( OperationsPolicy.Context_lookup );
policy.allow( OperationsPolicy.JNDI_access_to_java_comp_env );
- Object expected = policy;
- Object actual = basicMdbObject.getAllowedOperationsReport("businessMethod");
+ final Object expected = policy;
+ final Object actual = basicMdbObject.getAllowedOperationsReport("businessMethod");
assertNotNull("The OperationsPolicy is null", actual );
assertEquals( expected, actual );
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
Modified: tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/mdb/MdbAnnotatedFieldInjectionTests.java
URL: http://svn.apache.org/viewvc/tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/mdb/MdbAnnotatedFieldInjectionTests.java?rev=1608563&r1=1608562&r2=1608563&view=diff
==============================================================================
--- tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/mdb/MdbAnnotatedFieldInjectionTests.java (original)
+++ tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/mdb/MdbAnnotatedFieldInjectionTests.java Mon Jul 7 19:07:41 2014
@@ -35,7 +35,7 @@ public class MdbAnnotatedFieldInjectionT
protected void setUp() throws Exception {
super.setUp();
- Destination destination = (Destination) initialContext.lookup("AnnotatedFieldInjectionMdbBean");
+ final Destination destination = (Destination) initialContext.lookup("AnnotatedFieldInjectionMdbBean");
ejbObject = MdbProxy.newProxyInstance(EncMdbObject.class, connectionFactory, destination);
TestManager.getDatabase().createEntityTable();
}
@@ -44,7 +44,7 @@ public class MdbAnnotatedFieldInjectionT
MdbProxy.destroyProxy(ejbObject);
try {
TestManager.getDatabase().dropEntityTable();
- } catch (Exception e){
+ } catch (final Exception e){
throw e;
} finally {
super.tearDown();
@@ -54,9 +54,9 @@ public class MdbAnnotatedFieldInjectionT
public void test01_lookupStringEntry() {
try{
ejbObject.lookupStringEntry();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -64,9 +64,9 @@ public class MdbAnnotatedFieldInjectionT
public void test02_lookupDoubleEntry() {
try{
ejbObject.lookupDoubleEntry();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -74,9 +74,9 @@ public class MdbAnnotatedFieldInjectionT
public void test03_lookupLongEntry() {
try{
ejbObject.lookupLongEntry();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -84,9 +84,9 @@ public class MdbAnnotatedFieldInjectionT
public void test04_lookupFloatEntry() {
try{
ejbObject.lookupFloatEntry();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -94,9 +94,9 @@ public class MdbAnnotatedFieldInjectionT
public void test05_lookupIntegerEntry() {
try{
ejbObject.lookupIntegerEntry();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -104,9 +104,9 @@ public class MdbAnnotatedFieldInjectionT
public void test06_lookupShortEntry() {
try{
ejbObject.lookupShortEntry();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -114,9 +114,9 @@ public class MdbAnnotatedFieldInjectionT
public void test07_lookupBooleanEntry() {
try{
ejbObject.lookupBooleanEntry();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -124,9 +124,9 @@ public class MdbAnnotatedFieldInjectionT
public void test08_lookupByteEntry() {
try{
ejbObject.lookupByteEntry();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -134,9 +134,9 @@ public class MdbAnnotatedFieldInjectionT
public void test09_lookupCharacterEntry() {
try{
ejbObject.lookupCharacterEntry();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -144,9 +144,9 @@ public class MdbAnnotatedFieldInjectionT
public void test10_lookupEntityBean() {
try{
ejbObject.lookupEntityBean();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -154,9 +154,9 @@ public class MdbAnnotatedFieldInjectionT
public void test11_lookupStatefulBean() {
try{
ejbObject.lookupStatefulBean();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -164,9 +164,9 @@ public class MdbAnnotatedFieldInjectionT
public void test12_lookupStatelessBean() {
try{
ejbObject.lookupStatelessBean();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -174,9 +174,9 @@ public class MdbAnnotatedFieldInjectionT
public void test13_lookupResource() {
try{
ejbObject.lookupResource();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -184,9 +184,9 @@ public class MdbAnnotatedFieldInjectionT
public void test14_lookupPersistenceUnit() {
try{
ejbObject.lookupPersistenceUnit();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -194,9 +194,9 @@ public class MdbAnnotatedFieldInjectionT
public void test15_lookupPersistenceContext() {
try{
ejbObject.lookupPersistenceContext();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -204,9 +204,9 @@ public class MdbAnnotatedFieldInjectionT
public void test18_lookupMessageDrivenContext() {
try{
ejbObject.lookupMessageDrivenContext();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -214,9 +214,9 @@ public class MdbAnnotatedFieldInjectionT
public void test19_lookupStatelessBusinessLocal() {
try{
ejbObject.lookupStatelessBusinessLocal();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -224,9 +224,9 @@ public class MdbAnnotatedFieldInjectionT
public void test20_lookupStatelessBusinessRemote() {
try{
ejbObject.lookupStatelessBusinessRemote();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -234,9 +234,9 @@ public class MdbAnnotatedFieldInjectionT
public void test21_lookupStatefulBusinessLocal() {
try{
ejbObject.lookupStatefulBusinessLocal();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -244,9 +244,9 @@ public class MdbAnnotatedFieldInjectionT
public void test22_lookupStatefulBusinessRemote() {
try{
ejbObject.lookupStatefulBusinessRemote();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -254,9 +254,9 @@ public class MdbAnnotatedFieldInjectionT
public void test23_lookupJMSConnectionFactory() {
try{
ejbObject.lookupJMSConnectionFactory();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
Modified: tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/mdb/MdbConnectionFactoryTests.java
URL: http://svn.apache.org/viewvc/tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/mdb/MdbConnectionFactoryTests.java?rev=1608563&r1=1608562&r2=1608563&view=diff
==============================================================================
--- tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/mdb/MdbConnectionFactoryTests.java (original)
+++ tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/mdb/MdbConnectionFactoryTests.java Mon Jul 7 19:07:41 2014
@@ -34,7 +34,7 @@ public class MdbConnectionFactoryTests e
}
public void test01_createConnection() throws Exception {
- Connection connection = createConnection();
+ final Connection connection = createConnection();
try {
assertNotNull("Jms connection is null.", connection);
} finally {
@@ -43,24 +43,24 @@ public class MdbConnectionFactoryTests e
}
public void test02_directRpc() throws Exception {
- Connection connection = createConnection();
+ final Connection connection = createConnection();
Session session = null;
MessageProducer producer = null;
MessageConsumer consumer = null;
try {
// create request
- Map<String, Object> request = new TreeMap<String, Object>();
+ final Map<String, Object> request = new TreeMap<String, Object>();
request.put("method", "businessMethod(java.lang.String)");
request.put("args", new Object[]{"cheese"});
// initialize session
session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE);
- Destination requestQueue = session.createQueue("BasicMdb");
- Destination responseQueue = session.createTemporaryQueue();
+ final Destination requestQueue = session.createQueue("BasicMdb");
+ final Destination responseQueue = session.createTemporaryQueue();
// Create a request messages
- ObjectMessage requestMessage = session.createObjectMessage();
+ final ObjectMessage requestMessage = session.createObjectMessage();
requestMessage.setJMSReplyTo(responseQueue);
requestMessage.setObject((Serializable) request);
@@ -81,22 +81,22 @@ public class MdbConnectionFactoryTests e
// "***************************************\n\n");
// wait for response mesage
- Message message = consumer.receive(1000);
+ final Message message = consumer.receive(1000);
// verify message
assertNotNull("Did not get a response message", message);
assertTrue("Response message is not an ObjectMessage", message instanceof ObjectMessage);
- ObjectMessage responseMessage = (ObjectMessage) message;
- Serializable object = responseMessage.getObject();
+ final ObjectMessage responseMessage = (ObjectMessage) message;
+ final Serializable object = responseMessage.getObject();
assertNotNull("Response ObjectMessage contains a null object");
assertTrue("Response ObjectMessage does not contain an instance of Map", object instanceof Map);
- Map response = (Map) object;
+ final Map response = (Map) object;
// process results
if (response.containsKey("exception")) {
throw (Exception) response.get("return");
}
- String returnValue = (String) response.get("return");
+ final String returnValue = (String) response.get("return");
assertEquals("eseehc", returnValue);
} finally {
MdbUtil.close(producer);
@@ -106,9 +106,9 @@ public class MdbConnectionFactoryTests e
}
public void test03_proxy() throws Exception {
- BasicMdbObject basicMdbObject = MdbProxy.newProxyInstance(BasicMdbObject.class, connectionFactory, "BasicMdb");
+ final BasicMdbObject basicMdbObject = MdbProxy.newProxyInstance(BasicMdbObject.class, connectionFactory, "BasicMdb");
try {
- String returnValue = basicMdbObject.businessMethod("blah");
+ final String returnValue = basicMdbObject.businessMethod("blah");
assertEquals("halb", returnValue);
} finally {
MdbProxy.destroyProxy(basicMdbObject);
Modified: tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/mdb/MdbContextLookupTests.java
URL: http://svn.apache.org/viewvc/tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/mdb/MdbContextLookupTests.java?rev=1608563&r1=1608562&r2=1608563&view=diff
==============================================================================
--- tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/mdb/MdbContextLookupTests.java (original)
+++ tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/mdb/MdbContextLookupTests.java Mon Jul 7 19:07:41 2014
@@ -35,7 +35,7 @@ public class MdbContextLookupTests exten
protected void setUp() throws Exception {
super.setUp();
- Destination destination = (Destination) initialContext.lookup("ContextLookupMdbBean");
+ final Destination destination = (Destination) initialContext.lookup("ContextLookupMdbBean");
ejbObject = MdbProxy.newProxyInstance(EncMdbObject.class, connectionFactory, destination);
TestManager.getDatabase().createEntityTable();
}
@@ -45,7 +45,7 @@ public class MdbContextLookupTests exten
MdbProxy.destroyProxy(ejbObject);
try {
TestManager.getDatabase().dropEntityTable();
- } catch (Exception e){
+ } catch (final Exception e){
throw e;
} finally {
super.tearDown();
@@ -55,9 +55,9 @@ public class MdbContextLookupTests exten
public void test01_lookupStringEntry() {
try{
ejbObject.lookupStringEntry();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -65,9 +65,9 @@ public class MdbContextLookupTests exten
public void test02_lookupDoubleEntry() {
try{
ejbObject.lookupDoubleEntry();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -75,9 +75,9 @@ public class MdbContextLookupTests exten
public void test03_lookupLongEntry() {
try{
ejbObject.lookupLongEntry();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -85,9 +85,9 @@ public class MdbContextLookupTests exten
public void test04_lookupFloatEntry() {
try{
ejbObject.lookupFloatEntry();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -95,9 +95,9 @@ public class MdbContextLookupTests exten
public void test05_lookupIntegerEntry() {
try{
ejbObject.lookupIntegerEntry();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -105,9 +105,9 @@ public class MdbContextLookupTests exten
public void test06_lookupShortEntry() {
try{
ejbObject.lookupShortEntry();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -115,9 +115,9 @@ public class MdbContextLookupTests exten
public void test07_lookupBooleanEntry() {
try{
ejbObject.lookupBooleanEntry();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -125,9 +125,9 @@ public class MdbContextLookupTests exten
public void test08_lookupByteEntry() {
try{
ejbObject.lookupByteEntry();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -135,9 +135,9 @@ public class MdbContextLookupTests exten
public void test09_lookupCharacterEntry() {
try{
ejbObject.lookupCharacterEntry();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -145,9 +145,9 @@ public class MdbContextLookupTests exten
public void test10_lookupEntityBean() {
try{
ejbObject.lookupEntityBean();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -155,9 +155,9 @@ public class MdbContextLookupTests exten
public void test11_lookupStatefulBean() {
try{
ejbObject.lookupStatefulBean();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -165,9 +165,9 @@ public class MdbContextLookupTests exten
public void test12_lookupStatelessBean() {
try{
ejbObject.lookupStatelessBean();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -175,9 +175,9 @@ public class MdbContextLookupTests exten
public void test13_lookupResource() {
try{
ejbObject.lookupResource();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -185,9 +185,9 @@ public class MdbContextLookupTests exten
public void test14_lookupPersistenceUnit() {
try{
ejbObject.lookupPersistenceUnit();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -195,9 +195,9 @@ public class MdbContextLookupTests exten
public void test15_lookupPersistenceContext() {
try{
ejbObject.lookupPersistenceContext();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -205,9 +205,9 @@ public class MdbContextLookupTests exten
public void test18_lookupMessageDrivenContext() {
try{
ejbObject.lookupMessageDrivenContext();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -215,9 +215,9 @@ public class MdbContextLookupTests exten
public void test23_lookupJMSConnectionFactory() {
try{
ejbObject.lookupJMSConnectionFactory();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
Modified: tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/mdb/MdbFieldInjectionTests.java
URL: http://svn.apache.org/viewvc/tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/mdb/MdbFieldInjectionTests.java?rev=1608563&r1=1608562&r2=1608563&view=diff
==============================================================================
--- tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/mdb/MdbFieldInjectionTests.java (original)
+++ tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/mdb/MdbFieldInjectionTests.java Mon Jul 7 19:07:41 2014
@@ -31,7 +31,7 @@ public class MdbFieldInjectionTests exte
protected void setUp() throws Exception {
super.setUp();
- Destination destination = (Destination) initialContext.lookup("FieldInjectionMdbBean");
+ final Destination destination = (Destination) initialContext.lookup("FieldInjectionMdbBean");
ejbObject = MdbProxy.newProxyInstance(EncMdbObject.class, connectionFactory, destination);
TestManager.getDatabase().createEntityTable();
}
@@ -40,7 +40,7 @@ public class MdbFieldInjectionTests exte
MdbProxy.destroyProxy(ejbObject);
try {
TestManager.getDatabase().dropEntityTable();
- } catch (Exception e){
+ } catch (final Exception e){
throw e;
} finally {
super.tearDown();
@@ -50,9 +50,9 @@ public class MdbFieldInjectionTests exte
public void test01_lookupStringEntry() {
try{
ejbObject.lookupStringEntry();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -60,9 +60,9 @@ public class MdbFieldInjectionTests exte
public void test02_lookupDoubleEntry() {
try{
ejbObject.lookupDoubleEntry();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -70,9 +70,9 @@ public class MdbFieldInjectionTests exte
public void test03_lookupLongEntry() {
try{
ejbObject.lookupLongEntry();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -80,9 +80,9 @@ public class MdbFieldInjectionTests exte
public void test04_lookupFloatEntry() {
try{
ejbObject.lookupFloatEntry();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -90,9 +90,9 @@ public class MdbFieldInjectionTests exte
public void test05_lookupIntegerEntry() {
try{
ejbObject.lookupIntegerEntry();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -100,9 +100,9 @@ public class MdbFieldInjectionTests exte
public void test06_lookupShortEntry() {
try{
ejbObject.lookupShortEntry();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -110,9 +110,9 @@ public class MdbFieldInjectionTests exte
public void test07_lookupBooleanEntry() {
try{
ejbObject.lookupBooleanEntry();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -120,9 +120,9 @@ public class MdbFieldInjectionTests exte
public void test08_lookupByteEntry() {
try{
ejbObject.lookupByteEntry();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -130,9 +130,9 @@ public class MdbFieldInjectionTests exte
public void test09_lookupCharacterEntry() {
try{
ejbObject.lookupCharacterEntry();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -140,9 +140,9 @@ public class MdbFieldInjectionTests exte
public void test10_lookupEntityBean() {
try{
ejbObject.lookupEntityBean();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -150,9 +150,9 @@ public class MdbFieldInjectionTests exte
public void test11_lookupStatefulBean() {
try{
ejbObject.lookupStatefulBean();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -160,9 +160,9 @@ public class MdbFieldInjectionTests exte
public void test12_lookupStatelessBean() {
try{
ejbObject.lookupStatelessBean();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -170,9 +170,9 @@ public class MdbFieldInjectionTests exte
public void test13_lookupResource() {
try{
ejbObject.lookupResource();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -180,9 +180,9 @@ public class MdbFieldInjectionTests exte
public void test14_lookupPersistenceUnit() {
try{
ejbObject.lookupPersistenceUnit();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -190,9 +190,9 @@ public class MdbFieldInjectionTests exte
public void test15_lookupPersistenceContext() {
try{
ejbObject.lookupPersistenceContext();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -200,9 +200,9 @@ public class MdbFieldInjectionTests exte
public void test18_lookupMessageDrivenContext() {
try{
ejbObject.lookupMessageDrivenContext();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -210,9 +210,9 @@ public class MdbFieldInjectionTests exte
public void test19_lookupStatelessBusinessLocal() {
try{
ejbObject.lookupStatelessBusinessLocal();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -220,9 +220,9 @@ public class MdbFieldInjectionTests exte
public void test20_lookupStatelessBusinessRemote() {
try{
ejbObject.lookupStatelessBusinessRemote();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -230,9 +230,9 @@ public class MdbFieldInjectionTests exte
public void test21_lookupStatefulBusinessLocal() {
try{
ejbObject.lookupStatefulBusinessLocal();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -240,9 +240,9 @@ public class MdbFieldInjectionTests exte
public void test22_lookupStatefulBusinessRemote() {
try{
ejbObject.lookupStatefulBusinessRemote();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -250,9 +250,9 @@ public class MdbFieldInjectionTests exte
public void test23_lookupJMSConnectionFactory() {
try{
ejbObject.lookupJMSConnectionFactory();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
Modified: tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/mdb/MdbInterceptorTests.java
URL: http://svn.apache.org/viewvc/tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/mdb/MdbInterceptorTests.java?rev=1608563&r1=1608562&r2=1608563&view=diff
==============================================================================
--- tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/mdb/MdbInterceptorTests.java (original)
+++ tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/mdb/MdbInterceptorTests.java Mon Jul 7 19:07:41 2014
@@ -35,7 +35,7 @@ public class MdbInterceptorTests extends
protected void setUp() throws Exception {
super.setUp();
- Destination destination = (Destination) initialContext.lookup("InterceptorMdbBean");
+ final Destination destination = (Destination) initialContext.lookup("InterceptorMdbBean");
ejbObject = MdbProxy.newProxyInstance(InterceptorMdbObject.class, connectionFactory, destination);
TestManager.getDatabase().createEntityTable();
}
@@ -44,7 +44,7 @@ public class MdbInterceptorTests extends
MdbProxy.destroyProxy(ejbObject);
try {
TestManager.getDatabase().dropEntityTable();
- } catch (Exception e){
+ } catch (final Exception e){
throw e;
} finally {
super.tearDown();
@@ -54,9 +54,9 @@ public class MdbInterceptorTests extends
public void test01_checkClassLevelBusinessMethodInterception() {
try{
ejbObject.checkClassLevelBusinessMethodInterception();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -64,9 +64,9 @@ public class MdbInterceptorTests extends
public void test02_checkMethodLevelBusinessMethodInterception() {
try{
ejbObject.checkMethodLevelBusinessMethodInterception();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -74,9 +74,9 @@ public class MdbInterceptorTests extends
public void test03_checkClassLevelCreateMethodInterception() {
try{
ejbObject.checkClassLevelCreateMethodInterception();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -84,9 +84,9 @@ public class MdbInterceptorTests extends
public void test04_checkMethodLevelCreateMethodInterception() {
try{
ejbObject.checkMethodLevelCreateMethodInterception();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
Modified: tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/mdb/MdbJndiEncTests.java
URL: http://svn.apache.org/viewvc/tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/mdb/MdbJndiEncTests.java?rev=1608563&r1=1608562&r2=1608563&view=diff
==============================================================================
--- tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/mdb/MdbJndiEncTests.java (original)
+++ tomee/tomee/branches/tomee-1.7.x/itests/openejb-itests-client/src/main/java/org/apache/openejb/test/mdb/MdbJndiEncTests.java Mon Jul 7 19:07:41 2014
@@ -35,7 +35,7 @@ public class MdbJndiEncTests extends Mdb
protected void setUp() throws Exception {
super.setUp();
- Destination destination = (Destination) initialContext.lookup("EncMdbBean");
+ final Destination destination = (Destination) initialContext.lookup("EncMdbBean");
ejbObject = MdbProxy.newProxyInstance(EncMdbObject.class, connectionFactory, destination);
TestManager.getDatabase().createEntityTable();
}
@@ -45,7 +45,7 @@ public class MdbJndiEncTests extends Mdb
MdbProxy.destroyProxy(ejbObject);
try {
TestManager.getDatabase().dropEntityTable();
- } catch (Exception e){
+ } catch (final Exception e){
throw e;
} finally {
super.tearDown();
@@ -55,9 +55,9 @@ public class MdbJndiEncTests extends Mdb
public void test01_lookupStringEntry() {
try{
ejbObject.lookupStringEntry();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -65,9 +65,9 @@ public class MdbJndiEncTests extends Mdb
public void test02_lookupDoubleEntry() {
try{
ejbObject.lookupDoubleEntry();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -75,9 +75,9 @@ public class MdbJndiEncTests extends Mdb
public void test03_lookupLongEntry() {
try{
ejbObject.lookupLongEntry();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -85,9 +85,9 @@ public class MdbJndiEncTests extends Mdb
public void test04_lookupFloatEntry() {
try{
ejbObject.lookupFloatEntry();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -95,9 +95,9 @@ public class MdbJndiEncTests extends Mdb
public void test05_lookupIntegerEntry() {
try{
ejbObject.lookupIntegerEntry();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -105,9 +105,9 @@ public class MdbJndiEncTests extends Mdb
public void test06_lookupShortEntry() {
try{
ejbObject.lookupShortEntry();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -115,9 +115,9 @@ public class MdbJndiEncTests extends Mdb
public void test07_lookupBooleanEntry() {
try{
ejbObject.lookupBooleanEntry();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -125,9 +125,9 @@ public class MdbJndiEncTests extends Mdb
public void test08_lookupByteEntry() {
try{
ejbObject.lookupByteEntry();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -135,9 +135,9 @@ public class MdbJndiEncTests extends Mdb
public void test09_lookupCharacterEntry() {
try{
ejbObject.lookupCharacterEntry();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -145,9 +145,9 @@ public class MdbJndiEncTests extends Mdb
public void test10_lookupEntityBean() {
try{
ejbObject.lookupEntityBean();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -155,9 +155,9 @@ public class MdbJndiEncTests extends Mdb
public void test11_lookupStatefulBean() {
try{
ejbObject.lookupStatefulBean();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -165,9 +165,9 @@ public class MdbJndiEncTests extends Mdb
public void test12_lookupStatelessBean() {
try{
ejbObject.lookupStatelessBean();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -175,9 +175,9 @@ public class MdbJndiEncTests extends Mdb
public void test13_lookupResource() {
try{
ejbObject.lookupResource();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -185,9 +185,9 @@ public class MdbJndiEncTests extends Mdb
public void test14_lookupPersistenceUnit() {
try{
ejbObject.lookupPersistenceUnit();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -195,18 +195,18 @@ public class MdbJndiEncTests extends Mdb
public void test15_lookupSessionContext() {
try{
ejbObject.lookupMessageDrivenContext();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
public void test16_lookupPersistenceContext() {
try{
ejbObject.lookupPersistenceContext();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -214,9 +214,9 @@ public class MdbJndiEncTests extends Mdb
public void test18_lookupMessageDrivenContext() {
try{
ejbObject.lookupMessageDrivenContext();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -224,9 +224,9 @@ public class MdbJndiEncTests extends Mdb
public void test19_lookupStatelessBusinessLocal() {
try{
ejbObject.lookupStatelessBusinessLocal();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -234,9 +234,9 @@ public class MdbJndiEncTests extends Mdb
public void test20_lookupStatelessBusinessRemote() {
try{
ejbObject.lookupStatelessBusinessRemote();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -244,9 +244,9 @@ public class MdbJndiEncTests extends Mdb
public void test21_lookupStatefulBusinessLocal() {
try{
ejbObject.lookupStatefulBusinessLocal();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -254,9 +254,9 @@ public class MdbJndiEncTests extends Mdb
public void test22_lookupStatefulBusinessRemote() {
try{
ejbObject.lookupStatefulBusinessRemote();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}
@@ -264,9 +264,9 @@ public class MdbJndiEncTests extends Mdb
public void test23_lookupJMSConnectionFactory() {
try{
ejbObject.lookupJMSConnectionFactory();
- } catch (TestFailureException e){
+ } catch (final TestFailureException e){
throw e.error;
- } catch (Exception e){
+ } catch (final Exception e){
fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
}
}