001: /**
002: * EasyBeans
003: * Copyright (C) 2006 Bull S.A.S.
004: * Contact: easybeans@ow2.org
005: *
006: * This library is free software; you can redistribute it and/or
007: * modify it under the terms of the GNU Lesser General Public
008: * License as published by the Free Software Foundation; either
009: * version 2.1 of the License, or any later version.
010: *
011: * This library is distributed in the hope that it will be useful,
012: * but WITHOUT ANY WARRANTY; without even the implied warranty of
013: * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
014: * Lesser General Public License for more details.
015: *
016: * You should have received a copy of the GNU Lesser General Public
017: * License along with this library; if not, write to the Free Software
018: * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
019: * USA
020: *
021: * --------------------------------------------------------------------------
022: * $Id: TestSupportsExceptionRemoteSFSB.java 1970 2007-10-16 11:49:25Z benoitf $
023: * --------------------------------------------------------------------------
024: */package org.ow2.easybeans.tests.transaction.containermanaged.stateful;
025:
026: import org.ow2.easybeans.tests.common.ejbs.stateful.containermanaged.transaction.SFSBContainerTransactionSupportsRuntime;
027: import org.ow2.easybeans.tests.transaction.containermanaged.base.TestSupportsException;
028: import org.testng.annotations.BeforeMethod;
029: import org.testng.annotations.Test;
030:
031: /**
032: * Verifies if the container-managed transaction in the session bean is
033: * following the JSR 220. The container must handle the different types of
034: * exception in the transaction context. The items covered in this test are:
035: * 13.3
036: * @reference JSR 220-PROPOSED FINAL
037: * @requirement Application Server must be running; the bean .
038: * SFSBContainerTransactionSupportsNewApp,
039: * SFSBContainerTransactionSupportsNewRollback and
040: * SFSBContainerTransactionSupportsNewRuntime must be deployed for
041: * testing stateful session bean.
042: * @setup gets the reference of the bean and binds the databases specified in
043: * the EmbeddedTest.
044: * @author Gisele Pinheiro Souza
045: * @author Eduardo Studzinski Estima de Castro
046: */
047: public class TestSupportsExceptionRemoteSFSB extends
048: TestSupportsException {
049:
050: /**
051: * @see org.ow2.easybeans.tests.transaction.containermanaged.base.TestSupportsException
052: * @throws Exception if an error during the initialization occurs.
053: */
054: @Test(groups={"runtime exception tests"})
055: @Override
056: public void testCallOtherBeanNotSupWithoutTrans() throws Exception {
057: super .testCallOtherBeanNotSupWithoutTrans();
058: }
059:
060: /**
061: * @see org.ow2.easybeans.tests.transaction.containermanaged.base.TestSupportsException
062: * @throws Exception if an error during the initialization occurs.
063: */
064: @Test(groups={"runtime exception tests"})
065: @Override
066: public void testCallOtherBeanNotSupWithTrans() throws Exception {
067: super .testCallOtherBeanNotSupWithTrans();
068: }
069:
070: /**
071: * @see org.ow2.easybeans.tests.transaction.containermanaged.base.TestSupportsException
072: * @throws Exception if an error during the initialization occurs.
073: */
074: @Test(groups={"runtime exception tests"})
075: @Override
076: public void testCallOtherBeanReqWithoutTrans() throws Exception {
077: super .testCallOtherBeanReqWithoutTrans();
078: }
079:
080: /**
081: * @see org.ow2.easybeans.tests.transaction.containermanaged.base.TestSupportsException
082: * @throws Exception if an error during the initialization occurs.
083: */
084: @Test(groups={"runtime exception tests"})
085: @Override
086: public void testCallOtherBeanReqWithTrans() throws Exception {
087: super .testCallOtherBeanReqWithTrans();
088: }
089:
090: /**
091: * Creates a bean used during the tests before each test.
092: * @throws Exception if a lookup error occurs.
093: */
094: @Override
095: public void createBeanRuntime() throws Exception {
096: super
097: .createBeanRuntime(SFSBContainerTransactionSupportsRuntime.class);
098: }
099:
100: /**
101: * @see org.ow2.easybeans.tests.transaction.containermanaged.base.TestContainerTransactionException
102: * @throws Exception if an error during the initialization occurs.
103: */
104: @BeforeMethod
105: @Override
106: public void setup() throws Exception {
107: super.setup();
108: }
109:
110: }
|