[jboss-svn-commits] JBL Code SVN: r18754 - labs/jbosstm/trunk/XTS/WS-T/tests/src/com/arjuna/wst/tests/junit.
jboss-svn-commits at lists.jboss.org
jboss-svn-commits at lists.jboss.org
Fri Mar 7 05:44:20 EST 2008
Author: adinn
Date: 2008-03-07 05:44:20 -0500 (Fri, 07 Mar 2008)
New Revision: 18754
Removed:
labs/jbosstm/trunk/XTS/WS-T/tests/src/com/arjuna/wst/tests/junit/BAParticipantManagerCoordinatorTestCase.java
labs/jbosstm/trunk/XTS/WS-T/tests/src/com/arjuna/wst/tests/junit/BAParticipantManagerParticipantTestCase.java
labs/jbosstm/trunk/XTS/WS-T/tests/src/com/arjuna/wst/tests/junit/BAParticipantManagerServiceTestCase.java
labs/jbosstm/trunk/XTS/WS-T/tests/src/com/arjuna/wst/tests/junit/TestCoordinatorCallback.java
labs/jbosstm/trunk/XTS/WS-T/tests/src/com/arjuna/wst/tests/junit/TestCoordinatorCompletionCoordinatorCallback.java
labs/jbosstm/trunk/XTS/WS-T/tests/src/com/arjuna/wst/tests/junit/TestCoordinatorCompletionParticipantCallback.java
labs/jbosstm/trunk/XTS/WS-T/tests/src/com/arjuna/wst/tests/junit/TestParticipantCompletionCoordinatorCallback.java
labs/jbosstm/trunk/XTS/WS-T/tests/src/com/arjuna/wst/tests/junit/TestParticipantCompletionParticipantCallback.java
labs/jbosstm/trunk/XTS/WS-T/tests/src/com/arjuna/wst/tests/junit/TestParticipantManagerCoordinatorCallback.java
labs/jbosstm/trunk/XTS/WS-T/tests/src/com/arjuna/wst/tests/junit/TestParticipantManagerParticipantProcessor.java
Log:
deleting tests for services which no longer exist for JBTM-339
Deleted: labs/jbosstm/trunk/XTS/WS-T/tests/src/com/arjuna/wst/tests/junit/BAParticipantManagerCoordinatorTestCase.java
===================================================================
--- labs/jbosstm/trunk/XTS/WS-T/tests/src/com/arjuna/wst/tests/junit/BAParticipantManagerCoordinatorTestCase.java 2008-03-07 06:27:10 UTC (rev 18753)
+++ labs/jbosstm/trunk/XTS/WS-T/tests/src/com/arjuna/wst/tests/junit/BAParticipantManagerCoordinatorTestCase.java 2008-03-07 10:44:20 UTC (rev 18754)
@@ -1,124 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2006, Red Hat Middleware LLC, and individual contributors
- * as indicated by the @author tags.
- * See the copyright.txt in the distribution for a full listing
- * of individual contributors.
- * This copyrighted material is made available to anyone wishing to use,
- * modify, copy, or redistribute it subject to the terms and conditions
- * of the GNU General Public License, v. 2.0.
- * This program is distributed in the hope that it will be useful, but WITHOUT A
- * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
- * PARTICULAR PURPOSE. See the GNU General Public License for more details.
- * You should have received a copy of the GNU General Public License,
- * v. 2.0 along with this distribution; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
- * MA 02110-1301, USA.
- *
- * (C) 2005-2006,
- * @author JBoss Inc.
- */
-/*
- * Copyright (c) 2003, Arjuna Technologies Limited.
- *
- * $Id: BAParticipantManagerCoordinatorTestCase.java,v 1.7.6.1 2005/11/22 10:37:45 kconner Exp $
- */
-
-package com.arjuna.wst.tests.junit;
-
-import javax.xml.namespace.QName;
-
-import junit.framework.TestCase;
-
-import com.arjuna.webservices.SoapFault;
-import com.arjuna.webservices.SoapFaultType;
-import com.arjuna.webservices.SoapRegistry;
-import com.arjuna.webservices.wsaddr.AddressingContext;
-import com.arjuna.webservices.wsarj.InstanceIdentifier;
-import com.arjuna.webservices.wsarjtx.ArjunaTXConstants;
-import com.arjuna.webservices.wsarjtx.client.ParticipantManagerParticipantClient;
-import com.arjuna.webservices.wsarjtx.processors.ParticipantManagerParticipantProcessor;
-import com.arjuna.wst.tests.junit.TestParticipantManagerParticipantProcessor.ParticipantManagerParticipantDetails;
-
-public class BAParticipantManagerCoordinatorTestCase extends TestCase
-{
- private ParticipantManagerParticipantProcessor origParticipantManagerParticipantProcessor ;
-
- private TestParticipantManagerParticipantProcessor testParticipantManagerParticipantProcessor = new TestParticipantManagerParticipantProcessor() ;
- private String participantManagerParticipantService ;
-
- protected void setUp()
- throws Exception
- {
- origParticipantManagerParticipantProcessor = ParticipantManagerParticipantProcessor.setParticipant(testParticipantManagerParticipantProcessor) ;
- final SoapRegistry soapRegistry = SoapRegistry.getRegistry() ;
- participantManagerParticipantService = soapRegistry.getServiceURI(ArjunaTXConstants.SERVICE_PARTICIPANT_MANAGER_PARTICIPANT) ;
- }
-
- public void testSendExit()
- throws Exception
- {
- final String messageId = "testSendExit" ;
- final AddressingContext addressingContext = AddressingContext.createRequestContext(participantManagerParticipantService, messageId) ;
- final InstanceIdentifier instanceIdentifier = new InstanceIdentifier("2") ;
- ParticipantManagerParticipantClient.getClient().sendExit(addressingContext, instanceIdentifier) ;
-
- final ParticipantManagerParticipantDetails details = testParticipantManagerParticipantProcessor.getParticipantManagerParticipantDetails(messageId, 10000) ;
-
- assertTrue(details.hasExit()) ;
- }
-
- public void testSendCompleted()
- throws Exception
- {
- final String messageId = "testSendCompleted" ;
- final AddressingContext addressingContext = AddressingContext.createRequestContext(participantManagerParticipantService, messageId) ;
- final InstanceIdentifier instanceIdentifier = new InstanceIdentifier("2") ;
- ParticipantManagerParticipantClient.getClient().sendCompleted(addressingContext, instanceIdentifier) ;
-
- final ParticipantManagerParticipantDetails details = testParticipantManagerParticipantProcessor.getParticipantManagerParticipantDetails(messageId, 10000) ;
-
- assertTrue(details.hasCompleted()) ;
- }
-
- public void testSendFault()
- throws Exception
- {
- final String messageId = "testSendFault" ;
- final AddressingContext addressingContext = AddressingContext.createRequestContext(participantManagerParticipantService, messageId) ;
- final InstanceIdentifier instanceIdentifier = new InstanceIdentifier("2") ;
- ParticipantManagerParticipantClient.getClient().sendFault(addressingContext, instanceIdentifier) ;
-
- final ParticipantManagerParticipantDetails details = testParticipantManagerParticipantProcessor.getParticipantManagerParticipantDetails(messageId, 10000) ;
-
- assertTrue(details.hasFault()) ;
- }
-
- public void testSendError()
- throws Exception
- {
- final String messageId = "testSendFault" ;
- final AddressingContext addressingContext = AddressingContext.createRequestContext(participantManagerParticipantService, messageId) ;
- final InstanceIdentifier instanceIdentifier = new InstanceIdentifier("2") ;
-
- final String reason = "testSendFaultReason" ;
- final SoapFaultType soapFaultType = SoapFaultType.FAULT_SENDER ;
- final QName subcode = ArjunaTXConstants.UNKNOWNERROR_ERROR_CODE_QNAME ;
- final SoapFault soapFault = new SoapFault(soapFaultType, subcode, reason) ;
- ParticipantManagerParticipantClient.getClient().sendSoapFault(addressingContext, soapFault, instanceIdentifier) ;
-
- final ParticipantManagerParticipantDetails details = testParticipantManagerParticipantProcessor.getParticipantManagerParticipantDetails(messageId, 10000) ;
- final SoapFault receivedSoapFault = details.getSoapFault() ;
-
- assertNotNull(receivedSoapFault) ;
- assertEquals(soapFaultType, receivedSoapFault.getSoapFaultType()) ;
- assertEquals(subcode, receivedSoapFault.getSubcode()) ;
- assertEquals(reason, receivedSoapFault.getReason()) ;
- }
-
- protected void tearDown()
- throws Exception
- {
- ParticipantManagerParticipantProcessor.setParticipant(origParticipantManagerParticipantProcessor) ;
- }
-}
Deleted: labs/jbosstm/trunk/XTS/WS-T/tests/src/com/arjuna/wst/tests/junit/BAParticipantManagerParticipantTestCase.java
===================================================================
--- labs/jbosstm/trunk/XTS/WS-T/tests/src/com/arjuna/wst/tests/junit/BAParticipantManagerParticipantTestCase.java 2008-03-07 06:27:10 UTC (rev 18753)
+++ labs/jbosstm/trunk/XTS/WS-T/tests/src/com/arjuna/wst/tests/junit/BAParticipantManagerParticipantTestCase.java 2008-03-07 10:44:20 UTC (rev 18754)
@@ -1,225 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2006, Red Hat Middleware LLC, and individual contributors
- * as indicated by the @author tags.
- * See the copyright.txt in the distribution for a full listing
- * of individual contributors.
- * This copyrighted material is made available to anyone wishing to use,
- * modify, copy, or redistribute it subject to the terms and conditions
- * of the GNU General Public License, v. 2.0.
- * This program is distributed in the hope that it will be useful, but WITHOUT A
- * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
- * PARTICULAR PURPOSE. See the GNU General Public License for more details.
- * You should have received a copy of the GNU General Public License,
- * v. 2.0 along with this distribution; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
- * MA 02110-1301, USA.
- *
- * (C) 2005-2006,
- * @author JBoss Inc.
- */
-/*
- * Copyright (c) 2003, Arjuna Technologies Limited.
- *
- * $Id: BAParticipantManagerParticipantTestCase.java,v 1.7.6.1 2005/11/22 10:37:46 kconner Exp $
- */
-
-package com.arjuna.wst.tests.junit;
-
-import javax.xml.namespace.QName;
-
-import junit.framework.TestCase;
-
-import com.arjuna.webservices.SoapFault;
-import com.arjuna.webservices.SoapFaultType;
-import com.arjuna.webservices.SoapRegistry;
-import com.arjuna.webservices.wsaddr.AddressingContext;
-import com.arjuna.webservices.wsaddr.AttributedURIType;
-import com.arjuna.webservices.wsaddr.EndpointReferenceType;
-import com.arjuna.webservices.wsarj.ArjunaContext;
-import com.arjuna.webservices.wsarj.InstanceIdentifier;
-import com.arjuna.webservices.wsarjtx.ArjunaTXConstants;
-import com.arjuna.webservices.wsarjtx.NotificationType;
-import com.arjuna.webservices.wsarjtx.client.ParticipantManagerCoordinatorClient;
-import com.arjuna.webservices.wsarjtx.processors.ParticipantManagerCoordinatorProcessor;
-
-public class BAParticipantManagerParticipantTestCase extends TestCase
-{
- protected void setUp()
- throws Exception
- {
- final SoapRegistry soapRegistry = SoapRegistry.getRegistry() ;
- participantManagerParticipantServiceURI = soapRegistry.getServiceURI(ArjunaTXConstants.SERVICE_PARTICIPANT_MANAGER_PARTICIPANT) ;
- participantManagerCoordinatorServiceURI = soapRegistry.getServiceURI(ArjunaTXConstants.SERVICE_PARTICIPANT_MANAGER_COORDINATOR) ;
- }
-
- public void testSendComplete()
- throws Exception
- {
- final String messageId = "123456" ;
- final String instanceIdentifier = "testSendComplete" ;
- final EndpointReferenceType participantManagerParticipantService = new EndpointReferenceType(new AttributedURIType(participantManagerCoordinatorServiceURI)) ;
- InstanceIdentifier.setEndpointInstanceIdentifier(participantManagerParticipantService, instanceIdentifier) ;
- final AddressingContext addressingContext = AddressingContext.createRequestContext(participantManagerParticipantService, messageId) ;
-
- final TestParticipantManagerCoordinatorCallback callback = new TestParticipantManagerCoordinatorCallback() {
- public void complete(final NotificationType complete, final AddressingContext addressingContext, final ArjunaContext arjunaContext)
- {
- assertEquals(addressingContext.getTo().getValue(), participantManagerCoordinatorServiceURI);
- assertEquals(addressingContext.getFrom().getAddress().getValue(), participantManagerParticipantServiceURI);
- assertEquals(addressingContext.getReplyTo().getAddress().getValue(), participantManagerParticipantServiceURI);
- assertEquals(addressingContext.getMessageID().getValue(), messageId);
-
- assertNotNull(arjunaContext.getInstanceIdentifier()) ;
- assertEquals(instanceIdentifier, arjunaContext.getInstanceIdentifier().getInstanceIdentifier()) ;
- }
- };
- final ParticipantManagerCoordinatorProcessor coordinator = ParticipantManagerCoordinatorProcessor.getCoordinator() ;
- coordinator.registerCallback(instanceIdentifier, callback) ;
-
- try
- {
- ParticipantManagerCoordinatorClient.getClient().sendComplete(addressingContext, new InstanceIdentifier("sender")) ;
- callback.waitUntilTriggered() ;
- }
- finally
- {
- coordinator.removeCallback(instanceIdentifier) ;
- }
-
- assertTrue(callback.hasTriggered()) ;
- assertFalse(callback.hasFailed()) ;
- }
-
- public void testSendExited()
- throws Exception
- {
- final String messageId = "123456" ;
- final String instanceIdentifier = "testSendExited" ;
- final EndpointReferenceType participantManagerParticipantService = new EndpointReferenceType(new AttributedURIType(participantManagerCoordinatorServiceURI)) ;
- InstanceIdentifier.setEndpointInstanceIdentifier(participantManagerParticipantService, instanceIdentifier) ;
- final AddressingContext addressingContext = AddressingContext.createRequestContext(participantManagerParticipantService, messageId) ;
-
- final TestParticipantManagerCoordinatorCallback callback = new TestParticipantManagerCoordinatorCallback() {
- public void exited(final NotificationType exited, final AddressingContext addressingContext, final ArjunaContext arjunaContext)
- {
- assertEquals(addressingContext.getTo().getValue(), participantManagerCoordinatorServiceURI);
- assertEquals(addressingContext.getFrom().getAddress().getValue(), participantManagerParticipantServiceURI);
- assertEquals(addressingContext.getReplyTo().getAddress().getValue(), participantManagerParticipantServiceURI);
- assertEquals(addressingContext.getMessageID().getValue(), messageId);
-
- assertNotNull(arjunaContext.getInstanceIdentifier()) ;
- assertEquals(instanceIdentifier, arjunaContext.getInstanceIdentifier().getInstanceIdentifier()) ;
- }
- };
- final ParticipantManagerCoordinatorProcessor coordinator = ParticipantManagerCoordinatorProcessor.getCoordinator() ;
- coordinator.registerCallback(instanceIdentifier, callback) ;
-
- try
- {
- ParticipantManagerCoordinatorClient.getClient().sendExited(addressingContext, new InstanceIdentifier("sender")) ;
- callback.waitUntilTriggered() ;
- }
- finally
- {
- coordinator.removeCallback(instanceIdentifier) ;
- }
-
- assertTrue(callback.hasTriggered()) ;
- assertFalse(callback.hasFailed()) ;
- }
-
- public void testSendFaulted()
- throws Exception
- {
- final String messageId = "123456" ;
- final String instanceIdentifier = "testSendFaulted" ;
- final EndpointReferenceType participantManagerParticipantService = new EndpointReferenceType(new AttributedURIType(participantManagerCoordinatorServiceURI)) ;
- InstanceIdentifier.setEndpointInstanceIdentifier(participantManagerParticipantService, instanceIdentifier) ;
- final AddressingContext addressingContext = AddressingContext.createRequestContext(participantManagerParticipantService, messageId) ;
-
- final TestParticipantManagerCoordinatorCallback callback = new TestParticipantManagerCoordinatorCallback() {
- public void faulted(final NotificationType faulted, final AddressingContext addressingContext, final ArjunaContext arjunaContext)
- {
- assertEquals(addressingContext.getTo().getValue(), participantManagerCoordinatorServiceURI);
- assertEquals(addressingContext.getFrom().getAddress().getValue(), participantManagerParticipantServiceURI);
- assertEquals(addressingContext.getReplyTo().getAddress().getValue(), participantManagerParticipantServiceURI);
- assertEquals(addressingContext.getMessageID().getValue(), messageId);
-
- assertNotNull(arjunaContext.getInstanceIdentifier()) ;
- assertEquals(instanceIdentifier, arjunaContext.getInstanceIdentifier().getInstanceIdentifier()) ;
- }
- };
- final ParticipantManagerCoordinatorProcessor coordinator = ParticipantManagerCoordinatorProcessor.getCoordinator() ;
- coordinator.registerCallback(instanceIdentifier, callback) ;
-
- try
- {
- ParticipantManagerCoordinatorClient.getClient().sendFaulted(addressingContext, new InstanceIdentifier("sender")) ;
- callback.waitUntilTriggered() ;
- }
- finally
- {
- coordinator.removeCallback(instanceIdentifier) ;
- }
-
- assertTrue(callback.hasTriggered()) ;
- assertFalse(callback.hasFailed()) ;
- }
-
- public void testSendError()
- throws Exception
- {
- final String messageId = "123456" ;
- final String reason = "testSendErrorReason" ;
- final String instanceIdentifier = "testSendError" ;
- final EndpointReferenceType participantManagerParticipantService = new EndpointReferenceType(new AttributedURIType(participantManagerCoordinatorServiceURI)) ;
- InstanceIdentifier.setEndpointInstanceIdentifier(participantManagerParticipantService, instanceIdentifier) ;
- final AddressingContext addressingContext = AddressingContext.createRequestContext(participantManagerParticipantService, messageId) ;
-
- final SoapFaultType soapFaultType = SoapFaultType.FAULT_SENDER ;
- final QName subcode = ArjunaTXConstants.UNKNOWNERROR_ERROR_CODE_QNAME ;
- final SoapFault soapFault = new SoapFault(soapFaultType, subcode, reason) ;
-
- final TestParticipantManagerCoordinatorCallback callback = new TestParticipantManagerCoordinatorCallback() {
- public void soapFault(final SoapFault soapFault, final AddressingContext addressingContext, final ArjunaContext arjunaContext)
- {
- assertEquals(addressingContext.getTo().getValue(), participantManagerCoordinatorServiceURI);
- assertEquals(addressingContext.getFrom().getAddress().getValue(), participantManagerParticipantServiceURI);
- assertNull(addressingContext.getReplyTo());
- assertEquals(addressingContext.getMessageID().getValue(), messageId);
-
- assertNotNull(soapFault) ;
- assertEquals(soapFaultType, soapFault.getSoapFaultType()) ;
- assertEquals(subcode, soapFault.getSubcode()) ;
- assertEquals(reason, soapFault.getReason()) ;
-
- assertNotNull(arjunaContext.getInstanceIdentifier()) ;
- assertEquals(instanceIdentifier, arjunaContext.getInstanceIdentifier().getInstanceIdentifier()) ;
- }
- };
- final ParticipantManagerCoordinatorProcessor coordinator = ParticipantManagerCoordinatorProcessor.getCoordinator() ;
- coordinator.registerCallback(instanceIdentifier, callback) ;
-
- try
- {
- ParticipantManagerCoordinatorClient.getClient().sendSoapFault(addressingContext, soapFault, new InstanceIdentifier("sender")) ;
- callback.waitUntilTriggered() ;
- }
- finally
- {
- coordinator.removeCallback(instanceIdentifier) ;
- }
-
- assertTrue(callback.hasTriggered()) ;
- assertFalse(callback.hasFailed()) ;
- }
-
- protected void tearDown()
- throws Exception
- {
- }
-
- private String participantManagerParticipantServiceURI ;
- private String participantManagerCoordinatorServiceURI ;
-}
Deleted: labs/jbosstm/trunk/XTS/WS-T/tests/src/com/arjuna/wst/tests/junit/BAParticipantManagerServiceTestCase.java
===================================================================
--- labs/jbosstm/trunk/XTS/WS-T/tests/src/com/arjuna/wst/tests/junit/BAParticipantManagerServiceTestCase.java 2008-03-07 06:27:10 UTC (rev 18753)
+++ labs/jbosstm/trunk/XTS/WS-T/tests/src/com/arjuna/wst/tests/junit/BAParticipantManagerServiceTestCase.java 2008-03-07 10:44:20 UTC (rev 18754)
@@ -1,240 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2006, Red Hat Middleware LLC, and individual contributors
- * as indicated by the @author tags.
- * See the copyright.txt in the distribution for a full listing
- * of individual contributors.
- * This copyrighted material is made available to anyone wishing to use,
- * modify, copy, or redistribute it subject to the terms and conditions
- * of the GNU General Public License, v. 2.0.
- * This program is distributed in the hope that it will be useful, but WITHOUT A
- * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
- * PARTICULAR PURPOSE. See the GNU General Public License for more details.
- * You should have received a copy of the GNU General Public License,
- * v. 2.0 along with this distribution; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
- * MA 02110-1301, USA.
- *
- * (C) 2005-2006,
- * @author JBoss Inc.
- */
-/*
- * Copyright (c) 2003, Arjuna Technologies Limited.
- *
- * $Id: BAParticipantManagerServiceTestCase.java,v 1.7.6.1 2005/11/22 10:37:49 kconner Exp $
- */
-
-package com.arjuna.wst.tests.junit;
-
-import junit.framework.TestCase;
-
-import com.arjuna.webservices.SoapRegistry;
-import com.arjuna.webservices.wsaddr.AttributedURIType;
-import com.arjuna.webservices.wsaddr.EndpointReferenceType;
-import com.arjuna.webservices.wsarj.InstanceIdentifier;
-import com.arjuna.webservices.wsarjtx.ArjunaTXConstants;
-import com.arjuna.wst.BAParticipantManager;
-import com.arjuna.wst.SystemException;
-import com.arjuna.wst.UnknownTransactionException;
-import com.arjuna.wst.WrongStateException;
-import com.arjuna.wst.stub.BAParticipantManagerStub;
-import com.arjuna.wst.tests.TestUtil;
-
-public class BAParticipantManagerServiceTestCase extends TestCase
-{
- protected void setUp()
- throws Exception
- {
- final SoapRegistry soapRegistry = SoapRegistry.getRegistry() ;
- final String participantManagerParticipantServiceURI = soapRegistry.getServiceURI(ArjunaTXConstants.SERVICE_PARTICIPANT_MANAGER_PARTICIPANT) ;
-
- EndpointReferenceType noExceptionBAParticipantManagerCoordinator = new EndpointReferenceType(new AttributedURIType(participantManagerParticipantServiceURI));
- InstanceIdentifier.setEndpointInstanceIdentifier(noExceptionBAParticipantManagerCoordinator, TestUtil.NOEXCEPTION_PARTICIPANT_IDENTIFIER);
-
- EndpointReferenceType wrongStateExceptionBAParticipantManagerCoordinator = new EndpointReferenceType(new AttributedURIType(participantManagerParticipantServiceURI));
- InstanceIdentifier.setEndpointInstanceIdentifier(wrongStateExceptionBAParticipantManagerCoordinator, TestUtil.WRONGSTATEEXCEPTION_PARTICIPANT_IDENTIFIER);
-
- EndpointReferenceType systemExceptionBAParticipantManagerCoordinator = new EndpointReferenceType(new AttributedURIType(participantManagerParticipantServiceURI));
- InstanceIdentifier.setEndpointInstanceIdentifier(systemExceptionBAParticipantManagerCoordinator, TestUtil.SYSTEMEXCEPTION_PARTICIPANT_IDENTIFIER);
-
- EndpointReferenceType nonexistentBAParticipantManagerCoordinator = new EndpointReferenceType(new AttributedURIType(participantManagerParticipantServiceURI));
- InstanceIdentifier.setEndpointInstanceIdentifier(nonexistentBAParticipantManagerCoordinator, TestUtil.NONEXISTENT_PARTICIPANT_IDENTIFIER);
-
- _noExceptionBAParticipantManagerStub = new BAParticipantManagerStub("participantManagerCoordinator", noExceptionBAParticipantManagerCoordinator);
- _wrongStateExceptionBAParticipantManagerStub = new BAParticipantManagerStub("participantManagerCoordinator", wrongStateExceptionBAParticipantManagerCoordinator);
- _systemExceptionBAParticipantManagerStub = new BAParticipantManagerStub("participantManagerCoordinator", systemExceptionBAParticipantManagerCoordinator);
- _nonexistentBAParticipantManagerStub = new BAParticipantManagerStub("participantManagerCoordinator", nonexistentBAParticipantManagerCoordinator);
- }
-
- public void testCompletedWithNoException ()
- throws Exception
- {
- _noExceptionBAParticipantManagerStub.completed();
- }
-
- public void testExitWithNoException()
- throws Exception
- {
- _noExceptionBAParticipantManagerStub.exit();
- }
-
- public void testUnknownWithNoException()
- throws Exception
- {
- _noExceptionBAParticipantManagerStub.unknown();
- }
-
- public void testFaultWithNoException()
- throws Exception
- {
- _noExceptionBAParticipantManagerStub.fault();
- }
-
- public void testErrorWithNoException()
- throws Exception
- {
- _noExceptionBAParticipantManagerStub.error();
- }
-
- public void testCompletedWithWrongStateException()
- throws Exception
- {
- try
- {
- _wrongStateExceptionBAParticipantManagerStub.completed();
- fail("Expected exception \"WrongStateException\"");
- }
- catch (WrongStateException wrongStateException)
- {
- }
- }
-
- public void testExitWithWrongStateException()
- throws Exception
- {
- try
- {
- _wrongStateExceptionBAParticipantManagerStub.exit();
- fail("Expected exception \"WrongStateException\"");
- }
- catch (WrongStateException wrongStateException)
- {
- }
- }
-
- public void testCompletedWithSystemException()
- throws Exception
- {
- try
- {
- _systemExceptionBAParticipantManagerStub.completed();
- fail("Expected exception \"SystemException\"");
- }
- catch (SystemException systemException)
- {
- }
- }
-
- public void testExitWithSystemException()
- throws Exception
- {
- try
- {
- _systemExceptionBAParticipantManagerStub.exit();
- fail("Expected exception \"SystemException\"");
- }
- catch (SystemException systemException)
- {
- }
- }
-
- public void testFaultWithSystemException ()
- throws Exception
- {
- try
- {
- _systemExceptionBAParticipantManagerStub.fault();
- fail("Expected exception \"SystemException\"");
- }
- catch (SystemException systemException)
- {
- }
- }
-
- public void testUnknownWithSystemException ()
- throws Exception
- {
- _systemExceptionBAParticipantManagerStub.unknown();
- }
-
- public void testErrorWithSystemException ()
- throws Exception
- {
- _systemExceptionBAParticipantManagerStub.error();
- }
-
- public void testCompletedWithNonExistent()
- throws Exception
- {
- try
- {
- _nonexistentBAParticipantManagerStub.completed();
- fail("Expected exception \"UnknownTransactionException\"");
- }
- catch (UnknownTransactionException unknownTransactionException)
- {
- }
- }
-
- public void testExitWithNonExistent()
- throws Exception
- {
- try
- {
- _nonexistentBAParticipantManagerStub.exit();
- fail("Expected exception \"UnknownTransactionException\"");
- }
- catch (UnknownTransactionException unknownTransactionException)
- {
- }
- }
-
- public void testFaultWithNonExistent()
- throws Exception
- {
- try
- {
- _nonexistentBAParticipantManagerStub.fault();
- fail("Expected exception \"SystemException\"");
- }
- catch (SystemException systemException)
- {
- }
- }
-
- public void testUnknownWithNonExistent()
- throws Exception
- {
- _nonexistentBAParticipantManagerStub.unknown();
- }
-
- public void testErrorWithNonExistent()
- throws Exception
- {
- _nonexistentBAParticipantManagerStub.error();
- }
-
- protected void tearDown()
- throws Exception
- {
- _noExceptionBAParticipantManagerStub = null;
- _wrongStateExceptionBAParticipantManagerStub = null;
- _systemExceptionBAParticipantManagerStub = null;
- _nonexistentBAParticipantManagerStub = null;
- }
-
- private BAParticipantManager _noExceptionBAParticipantManagerStub = null;
- private BAParticipantManager _wrongStateExceptionBAParticipantManagerStub = null;
- private BAParticipantManager _systemExceptionBAParticipantManagerStub = null;
- private BAParticipantManager _nonexistentBAParticipantManagerStub = null;
-}
Deleted: labs/jbosstm/trunk/XTS/WS-T/tests/src/com/arjuna/wst/tests/junit/TestCoordinatorCallback.java
===================================================================
--- labs/jbosstm/trunk/XTS/WS-T/tests/src/com/arjuna/wst/tests/junit/TestCoordinatorCallback.java 2008-03-07 06:27:10 UTC (rev 18753)
+++ labs/jbosstm/trunk/XTS/WS-T/tests/src/com/arjuna/wst/tests/junit/TestCoordinatorCallback.java 2008-03-07 10:44:20 UTC (rev 18754)
@@ -1,106 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2006, Red Hat Middleware LLC, and individual contributors
- * as indicated by the @author tags.
- * See the copyright.txt in the distribution for a full listing
- * of individual contributors.
- * This copyrighted material is made available to anyone wishing to use,
- * modify, copy, or redistribute it subject to the terms and conditions
- * of the GNU General Public License, v. 2.0.
- * This program is distributed in the hope that it will be useful, but WITHOUT A
- * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
- * PARTICULAR PURPOSE. See the GNU General Public License for more details.
- * You should have received a copy of the GNU General Public License,
- * v. 2.0 along with this distribution; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
- * MA 02110-1301, USA.
- *
- * (C) 2005-2006,
- * @author JBoss Inc.
- */
-package com.arjuna.wst.tests.junit;
-
-import com.arjuna.webservices.SoapFault;
-import com.arjuna.webservices.wsaddr.AddressingContext;
-import com.arjuna.webservices.wsarj.ArjunaContext;
-import com.arjuna.webservices.wsat.NotificationType;
-import com.arjuna.webservices.wsat.processors.CoordinatorCallback;
-
-/**
- * Base callback class for tests.
- * @author kevin
- */
-public class TestCoordinatorCallback extends CoordinatorCallback
-{
- /**
- * An aborted response.
- * @param aborted The aborted notification.
- * @param addressingContext The addressing context.
- * @param arjunaContext The arjuna context.
- */
- public void aborted(final NotificationType aborted, final AddressingContext addressingContext,
- final ArjunaContext arjunaContext)
- {
- throw new RuntimeException("Unexpected aborted response") ;
- }
-
- /**
- * A committed response.
- * @param committed The committed notification.
- * @param addressingContext The addressing context.
- * @param arjunaContext The arjuna context.
- */
- public void committed(final NotificationType committed, final AddressingContext addressingContext,
- final ArjunaContext arjunaContext)
- {
- throw new RuntimeException("Unexpected committed response") ;
- }
-
- /**
- * A prepared response.
- * @param prepared The prepared notification.
- * @param addressingContext The addressing context.
- * @param arjunaContext The arjuna context.
- */
- public void prepared(final NotificationType prepared, final AddressingContext addressingContext,
- final ArjunaContext arjunaContext)
- {
- throw new RuntimeException("Unexpected prepared response") ;
- }
-
- /**
- * A read only response.
- * @param readOnly The read only notification.
- * @param addressingContext The addressing context.
- * @param arjunaContext The arjuna context.
- */
- public void readOnly(final NotificationType readOnly, final AddressingContext addressingContext,
- final ArjunaContext arjunaContext)
- {
- throw new RuntimeException("Unexpected read only response") ;
- }
-
- /**
- * A replay response.
- * @param replay The replay notification.
- * @param addressingContext The addressing context.
- * @param arjunaContext The arjuna context.
- */
- public void replay(final NotificationType replay, final AddressingContext addressingContext,
- final ArjunaContext arjunaContext)
- {
- throw new RuntimeException("Unexpected replay response") ;
- }
-
- /**
- * A SOAP fault response.
- * @param soapFault The SOAP fault.
- * @param addressingContext The addressing context.
- * @param arjunaContext The arjuna context.
- */
- public void soapFault(final SoapFault soapFault, final AddressingContext addressingContext,
- final ArjunaContext arjunaContext)
- {
- throw new RuntimeException("Unexpected SOAP fault response") ;
- }
-}
Deleted: labs/jbosstm/trunk/XTS/WS-T/tests/src/com/arjuna/wst/tests/junit/TestCoordinatorCompletionCoordinatorCallback.java
===================================================================
--- labs/jbosstm/trunk/XTS/WS-T/tests/src/com/arjuna/wst/tests/junit/TestCoordinatorCompletionCoordinatorCallback.java 2008-03-07 06:27:10 UTC (rev 18753)
+++ labs/jbosstm/trunk/XTS/WS-T/tests/src/com/arjuna/wst/tests/junit/TestCoordinatorCompletionCoordinatorCallback.java 2008-03-07 10:44:20 UTC (rev 18754)
@@ -1,116 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2006, Red Hat Middleware LLC, and individual contributors
- * as indicated by the @author tags.
- * See the copyright.txt in the distribution for a full listing
- * of individual contributors.
- * This copyrighted material is made available to anyone wishing to use,
- * modify, copy, or redistribute it subject to the terms and conditions
- * of the GNU General Public License, v. 2.0.
- * This program is distributed in the hope that it will be useful, but WITHOUT A
- * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
- * PARTICULAR PURPOSE. See the GNU General Public License for more details.
- * You should have received a copy of the GNU General Public License,
- * v. 2.0 along with this distribution; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
- * MA 02110-1301, USA.
- *
- * (C) 2005-2006,
- * @author JBoss Inc.
- */
-package com.arjuna.wst.tests.junit;
-
-import com.arjuna.webservices.SoapFault;
-import com.arjuna.webservices.wsaddr.AddressingContext;
-import com.arjuna.webservices.wsarj.ArjunaContext;
-import com.arjuna.webservices.wsba.ExceptionType;
-import com.arjuna.webservices.wsba.NotificationType;
-import com.arjuna.webservices.wsba.StatusType;
-import com.arjuna.webservices.wsba.processors.CoordinatorCompletionCoordinatorCallback;
-
-
-/**
- * Base callback class for tests.
- * @author kevin
- */
-public class TestCoordinatorCompletionCoordinatorCallback extends CoordinatorCompletionCoordinatorCallback
-{
- /**
- * A cancelled response.
- * @param cancelled The cancelled notification.
- * @param addressingContext The addressing context.
- * @param arjunaContext The arjuna context.
- */
- public void cancelled(final NotificationType cancelled, final AddressingContext addressingContext, final ArjunaContext arjunaContext)
- {
- throw new RuntimeException("Unexpected cancelled response") ;
- }
-
- /**
- * A closed response.
- * @param closed The closed notification.
- * @param addressingContext The addressing context.
- * @param arjunaContext The arjuna context.
- */
- public void closed(final NotificationType closed, final AddressingContext addressingContext, final ArjunaContext arjunaContext)
- {
- throw new RuntimeException("Unexpected closed response") ;
- }
-
- /**
- * A compensated response.
- * @param compensated The compensated notification.
- * @param addressingContext The addressing context.
- * @param arjunaContext The arjuna context.
- */
- public void compensated(final NotificationType compensated, final AddressingContext addressingContext, final ArjunaContext arjunaContext)
- {
- throw new RuntimeException("Unexpected compensated response") ;
- }
-
- /**
- * A completed response.
- * @param completed The completed notification.
- * @param addressingContext The addressing context.
- * @param arjunaContext The arjuna context.
- */
- public void completed(final NotificationType completed, final AddressingContext addressingContext,
- final ArjunaContext arjunaContext)
- {
- throw new RuntimeException("Unexpected completed response") ;
- }
-
- /**
- * A Status.
- * @param status The status notification.
- * @param addressingContext The addressing context.
- * @param arjunaContext The arjuna context.
- */
- public void status(final StatusType status, final AddressingContext addressingContext, final ArjunaContext arjunaContext)
- {
- throw new RuntimeException("Unexpected status response") ;
- }
-
- /**
- * A fault response.
- * @param fault The fault notification.
- * @param addressingContext The addressing context.
- * @param arjunaContext The arjuna context.
- */
- public void fault(final ExceptionType fault, final AddressingContext addressingContext, final ArjunaContext arjunaContext)
- {
- throw new RuntimeException("Unexpected fault response") ;
- }
-
- /**
- * A SOAP fault response.
- * @param soapFault The SOAP fault.
- * @param addressingContext The addressing context.
- * @param arjunaContext The arjuna context.
- */
- public void soapFault(final SoapFault soapFault, final AddressingContext addressingContext,
- final ArjunaContext arjunaContext)
- {
- throw new RuntimeException("Unexpected SOAP fault response") ;
- }
-}
Deleted: labs/jbosstm/trunk/XTS/WS-T/tests/src/com/arjuna/wst/tests/junit/TestCoordinatorCompletionParticipantCallback.java
===================================================================
--- labs/jbosstm/trunk/XTS/WS-T/tests/src/com/arjuna/wst/tests/junit/TestCoordinatorCompletionParticipantCallback.java 2008-03-07 06:27:10 UTC (rev 18753)
+++ labs/jbosstm/trunk/XTS/WS-T/tests/src/com/arjuna/wst/tests/junit/TestCoordinatorCompletionParticipantCallback.java 2008-03-07 10:44:20 UTC (rev 18754)
@@ -1,81 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2006, Red Hat Middleware LLC, and individual contributors
- * as indicated by the @author tags.
- * See the copyright.txt in the distribution for a full listing
- * of individual contributors.
- * This copyrighted material is made available to anyone wishing to use,
- * modify, copy, or redistribute it subject to the terms and conditions
- * of the GNU General Public License, v. 2.0.
- * This program is distributed in the hope that it will be useful, but WITHOUT A
- * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
- * PARTICULAR PURPOSE. See the GNU General Public License for more details.
- * You should have received a copy of the GNU General Public License,
- * v. 2.0 along with this distribution; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
- * MA 02110-1301, USA.
- *
- * (C) 2005-2006,
- * @author JBoss Inc.
- */
-package com.arjuna.wst.tests.junit;
-
-import com.arjuna.webservices.SoapFault;
-import com.arjuna.webservices.wsaddr.AddressingContext;
-import com.arjuna.webservices.wsarj.ArjunaContext;
-import com.arjuna.webservices.wsba.NotificationType;
-import com.arjuna.webservices.wsba.StatusType;
-import com.arjuna.webservices.wsba.processors.CoordinatorCompletionParticipantCallback;
-
-
-/**
- * Base callback class for tests.
- * @author kevin
- */
-public class TestCoordinatorCompletionParticipantCallback extends CoordinatorCompletionParticipantCallback
-{
- /**
- * An exited response.
- * @param exited The exited notification.
- * @param addressingContext The addressing context.
- * @param arjunaContext The arjuna context.
- */
- public void exited(final NotificationType exited, final AddressingContext addressingContext, final ArjunaContext arjunaContext)
- {
- throw new RuntimeException("Unexpected exited response") ;
- }
-
- /**
- * A faulted response.
- * @param faulted The faulted notification.
- * @param addressingContext The addressing context.
- * @param arjunaContext The arjuna context.
- */
- public void faulted(final NotificationType faulted, final AddressingContext addressingContext, final ArjunaContext arjunaContext)
- {
- throw new RuntimeException("Unexpected faulted response") ;
- }
-
- /**
- * A status response.
- * @param status The status notification.
- * @param addressingContext The addressing context.
- * @param arjunaContext The arjuna context.
- */
- public void status(final StatusType status, final AddressingContext addressingContext, final ArjunaContext arjunaContext)
- {
- throw new RuntimeException("Unexpected status response") ;
- }
-
- /**
- * A SOAP fault response.
- * @param soapFault The SOAP fault.
- * @param addressingContext The addressing context.
- * @param arjunaContext The arjuna context.
- */
- public void soapFault(final SoapFault soapFault, final AddressingContext addressingContext,
- final ArjunaContext arjunaContext)
- {
- throw new RuntimeException("Unexpected SOAP fault response") ;
- }
-}
Deleted: labs/jbosstm/trunk/XTS/WS-T/tests/src/com/arjuna/wst/tests/junit/TestParticipantCompletionCoordinatorCallback.java
===================================================================
--- labs/jbosstm/trunk/XTS/WS-T/tests/src/com/arjuna/wst/tests/junit/TestParticipantCompletionCoordinatorCallback.java 2008-03-07 06:27:10 UTC (rev 18753)
+++ labs/jbosstm/trunk/XTS/WS-T/tests/src/com/arjuna/wst/tests/junit/TestParticipantCompletionCoordinatorCallback.java 2008-03-07 10:44:20 UTC (rev 18754)
@@ -1,117 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2006, Red Hat Middleware LLC, and individual contributors
- * as indicated by the @author tags.
- * See the copyright.txt in the distribution for a full listing
- * of individual contributors.
- * This copyrighted material is made available to anyone wishing to use,
- * modify, copy, or redistribute it subject to the terms and conditions
- * of the GNU General Public License, v. 2.0.
- * This program is distributed in the hope that it will be useful, but WITHOUT A
- * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
- * PARTICULAR PURPOSE. See the GNU General Public License for more details.
- * You should have received a copy of the GNU General Public License,
- * v. 2.0 along with this distribution; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
- * MA 02110-1301, USA.
- *
- * (C) 2005-2006,
- * @author JBoss Inc.
- */
-package com.arjuna.wst.tests.junit;
-
-import com.arjuna.webservices.SoapFault;
-import com.arjuna.webservices.wsaddr.AddressingContext;
-import com.arjuna.webservices.wsarj.ArjunaContext;
-import com.arjuna.webservices.wsba.ExceptionType;
-import com.arjuna.webservices.wsba.NotificationType;
-import com.arjuna.webservices.wsba.StatusType;
-import com.arjuna.webservices.wsba.processors.ParticipantCompletionCoordinatorCallback;
-
-
-/**
- * Base callback class for tests.
- * @author kevin
- */
-public class TestParticipantCompletionCoordinatorCallback extends ParticipantCompletionCoordinatorCallback
-{
- /**
- * A cancelled response.
- * @param cancelled The cancelled notification.
- * @param addressingContext The addressing context.
- * @param arjunaContext The arjuna context.
- */
- public void cancelled(final NotificationType cancelled, final AddressingContext addressingContext, final ArjunaContext arjunaContext)
- {
- throw new RuntimeException("Unexpected cancelled response") ;
- }
-
- /**
- * A closed response.
- * @param closed The closed notification.
- * @param addressingContext The addressing context.
- * @param arjunaContext The arjuna context.
- */
- public void closed(final NotificationType closed, final AddressingContext addressingContext, final ArjunaContext arjunaContext)
- {
- throw new RuntimeException("Unexpected closed response") ;
- }
-
- /**
- * A compensated response.
- * @param compensated The compensated notification.
- * @param addressingContext The addressing context.
- * @param arjunaContext The arjuna context.
- */
- public void compensated(final NotificationType compensated, final AddressingContext addressingContext, final ArjunaContext arjunaContext)
- {
- throw new RuntimeException("Unexpected compensated response") ;
- }
-
- /**
- * A completed response.
- * @param completed The completed notification.
- * @param addressingContext The addressing context.
- * @param arjunaContext The arjuna context.
- */
- public void completed(final NotificationType completed, final AddressingContext addressingContext,
- final ArjunaContext arjunaContext)
- {
- throw new RuntimeException("Unexpected completed response") ;
- }
-
- /**
- * A Status.
- * @param status The status notification.
- * @param addressingContext The addressing context.
- * @param arjunaContext The arjuna context.
- */
- public void status(final StatusType status, final AddressingContext addressingContext, final ArjunaContext arjunaContext)
- {
- throw new RuntimeException("Unexpected status response") ;
- }
-
- /**
- * A SOAP fault response.
- * @param soapFault The SOAP fault.
- * @param addressingContext The addressing context.
- * @param arjunaContext The arjuna context.
- */
- public void soapFault(final SoapFault soapFault, final AddressingContext addressingContext,
- final ArjunaContext arjunaContext)
- {
- throw new RuntimeException("Unexpected SOAP fault response") ;
- }
-
- /**
- * A fault response.
- * @param fault The fault.
- * @param addressingContext The addressing context.
- * @param arjunaContext The arjuna context.
- */
- public void fault(final ExceptionType fault, final AddressingContext addressingContext,
- final ArjunaContext arjunaContext)
- {
- throw new RuntimeException("Unexpected fault response") ;
- }
-}
Deleted: labs/jbosstm/trunk/XTS/WS-T/tests/src/com/arjuna/wst/tests/junit/TestParticipantCompletionParticipantCallback.java
===================================================================
--- labs/jbosstm/trunk/XTS/WS-T/tests/src/com/arjuna/wst/tests/junit/TestParticipantCompletionParticipantCallback.java 2008-03-07 06:27:10 UTC (rev 18753)
+++ labs/jbosstm/trunk/XTS/WS-T/tests/src/com/arjuna/wst/tests/junit/TestParticipantCompletionParticipantCallback.java 2008-03-07 10:44:20 UTC (rev 18754)
@@ -1,81 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2006, Red Hat Middleware LLC, and individual contributors
- * as indicated by the @author tags.
- * See the copyright.txt in the distribution for a full listing
- * of individual contributors.
- * This copyrighted material is made available to anyone wishing to use,
- * modify, copy, or redistribute it subject to the terms and conditions
- * of the GNU General Public License, v. 2.0.
- * This program is distributed in the hope that it will be useful, but WITHOUT A
- * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
- * PARTICULAR PURPOSE. See the GNU General Public License for more details.
- * You should have received a copy of the GNU General Public License,
- * v. 2.0 along with this distribution; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
- * MA 02110-1301, USA.
- *
- * (C) 2005-2006,
- * @author JBoss Inc.
- */
-package com.arjuna.wst.tests.junit;
-
-import com.arjuna.webservices.SoapFault;
-import com.arjuna.webservices.wsaddr.AddressingContext;
-import com.arjuna.webservices.wsarj.ArjunaContext;
-import com.arjuna.webservices.wsba.NotificationType;
-import com.arjuna.webservices.wsba.StatusType;
-import com.arjuna.webservices.wsba.processors.ParticipantCompletionParticipantCallback;
-
-
-/**
- * Base callback class for tests.
- * @author kevin
- */
-public class TestParticipantCompletionParticipantCallback extends ParticipantCompletionParticipantCallback
-{
- /**
- * An exited response.
- * @param exited The exited notification.
- * @param addressingContext The addressing context.
- * @param arjunaContext The arjuna context.
- */
- public void exited(final NotificationType exited, final AddressingContext addressingContext, final ArjunaContext arjunaContext)
- {
- throw new RuntimeException("Unexpected exited response") ;
- }
-
- /**
- * A faulted response.
- * @param faulted The faulted notification.
- * @param addressingContext The addressing context.
- * @param arjunaContext The arjuna context.
- */
- public void faulted(final NotificationType faulted, final AddressingContext addressingContext, final ArjunaContext arjunaContext)
- {
- throw new RuntimeException("Unexpected faulted response") ;
- }
-
- /**
- * A status response.
- * @param status The status notification.
- * @param addressingContext The addressing context.
- * @param arjunaContext The arjuna context.
- */
- public void status(final StatusType status, final AddressingContext addressingContext, final ArjunaContext arjunaContext)
- {
- throw new RuntimeException("Unexpected status response") ;
- }
-
- /**
- * A SOAP fault response.
- * @param soapFault The SOAP fault.
- * @param addressingContext The addressing context.
- * @param arjunaContext The arjuna context.
- */
- public void soapFault(final SoapFault soapFault, final AddressingContext addressingContext,
- final ArjunaContext arjunaContext)
- {
- throw new RuntimeException("Unexpected SOAP fault response") ;
- }
-}
Deleted: labs/jbosstm/trunk/XTS/WS-T/tests/src/com/arjuna/wst/tests/junit/TestParticipantManagerCoordinatorCallback.java
===================================================================
--- labs/jbosstm/trunk/XTS/WS-T/tests/src/com/arjuna/wst/tests/junit/TestParticipantManagerCoordinatorCallback.java 2008-03-07 06:27:10 UTC (rev 18753)
+++ labs/jbosstm/trunk/XTS/WS-T/tests/src/com/arjuna/wst/tests/junit/TestParticipantManagerCoordinatorCallback.java 2008-03-07 10:44:20 UTC (rev 18754)
@@ -1,82 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2006, Red Hat Middleware LLC, and individual contributors
- * as indicated by the @author tags.
- * See the copyright.txt in the distribution for a full listing
- * of individual contributors.
- * This copyrighted material is made available to anyone wishing to use,
- * modify, copy, or redistribute it subject to the terms and conditions
- * of the GNU General Public License, v. 2.0.
- * This program is distributed in the hope that it will be useful, but WITHOUT A
- * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
- * PARTICULAR PURPOSE. See the GNU General Public License for more details.
- * You should have received a copy of the GNU General Public License,
- * v. 2.0 along with this distribution; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
- * MA 02110-1301, USA.
- *
- * (C) 2005-2006,
- * @author JBoss Inc.
- */
-package com.arjuna.wst.tests.junit;
-
-import com.arjuna.webservices.SoapFault;
-import com.arjuna.webservices.wsaddr.AddressingContext;
-import com.arjuna.webservices.wsarj.ArjunaContext;
-import com.arjuna.webservices.wsarjtx.NotificationType;
-import com.arjuna.webservices.wsarjtx.processors.ParticipantManagerCoordinatorCallback;
-
-/**
- * Base callback class for tests.
- * @author kevin
- */
-public class TestParticipantManagerCoordinatorCallback extends ParticipantManagerCoordinatorCallback
-{
- /**
- * A complete response.
- * @param complete The complete notification.
- * @param addressingContext The addressing context.
- * @param arjunaContext The arjuna context.
- */
- public void complete(final NotificationType complete, final AddressingContext addressingContext,
- final ArjunaContext arjunaContext)
- {
- throw new RuntimeException("Unexpected complete response") ;
- }
-
- /**
- * An exited response.
- * @param exited The exited notification.
- * @param addressingContext The addressing context.
- * @param arjunaContext The arjuna context.
- */
- public void exited(final NotificationType exited, final AddressingContext addressingContext,
- final ArjunaContext arjunaContext)
- {
- throw new RuntimeException("Unexpected exited response") ;
- }
-
- /**
- * A faulted response.
- * @param faulted The faulted notification.
- * @param addressingContext The addressing context.
- * @param arjunaContext The arjuna context.
- */
- public void faulted(final NotificationType faulted, final AddressingContext addressingContext,
- final ArjunaContext arjunaContext)
- {
- throw new RuntimeException("Unexpected faulted response") ;
- }
-
- /**
- * A SOAP fault response.
- * @param soapFault The SOAP fault.
- * @param addressingContext The addressing context.
- * @param arjunaContext The arjuna context.
- */
- public void soapFault(final SoapFault soapFault, final AddressingContext addressingContext,
- final ArjunaContext arjunaContext)
- {
- throw new RuntimeException("Unexpected SOAP fault response") ;
- }
-}
Deleted: labs/jbosstm/trunk/XTS/WS-T/tests/src/com/arjuna/wst/tests/junit/TestParticipantManagerParticipantProcessor.java
===================================================================
--- labs/jbosstm/trunk/XTS/WS-T/tests/src/com/arjuna/wst/tests/junit/TestParticipantManagerParticipantProcessor.java 2008-03-07 06:27:10 UTC (rev 18753)
+++ labs/jbosstm/trunk/XTS/WS-T/tests/src/com/arjuna/wst/tests/junit/TestParticipantManagerParticipantProcessor.java 2008-03-07 10:44:20 UTC (rev 18754)
@@ -1,197 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2006, Red Hat Middleware LLC, and individual contributors
- * as indicated by the @author tags.
- * See the copyright.txt in the distribution for a full listing
- * of individual contributors.
- * This copyrighted material is made available to anyone wishing to use,
- * modify, copy, or redistribute it subject to the terms and conditions
- * of the GNU General Public License, v. 2.0.
- * This program is distributed in the hope that it will be useful, but WITHOUT A
- * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
- * PARTICULAR PURPOSE. See the GNU General Public License for more details.
- * You should have received a copy of the GNU General Public License,
- * v. 2.0 along with this distribution; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
- * MA 02110-1301, USA.
- *
- * (C) 2005-2006,
- * @author JBoss Inc.
- */
-package com.arjuna.wst.tests.junit;
-
-import java.util.HashMap;
-import java.util.Map;
-
-import com.arjuna.webservices.SoapFault;
-import com.arjuna.webservices.wsaddr.AddressingContext;
-import com.arjuna.webservices.wsarj.ArjunaContext;
-import com.arjuna.webservices.wsarjtx.processors.ParticipantManagerParticipantProcessor;
-import com.arjuna.webservices.wsat.NotificationType;
-import com.arjuna.wst.BAParticipantManager;
-
-public class TestParticipantManagerParticipantProcessor extends
- ParticipantManagerParticipantProcessor
-{
- private Map messageIdMap = new HashMap() ;
-
- public ParticipantManagerParticipantDetails getParticipantManagerParticipantDetails(final String messageId, final long timeout)
- {
- final long endTime = System.currentTimeMillis() + timeout ;
- synchronized(messageIdMap)
- {
- long now = System.currentTimeMillis() ;
- while(now < endTime)
- {
- final ParticipantManagerParticipantDetails details = (ParticipantManagerParticipantDetails)messageIdMap.remove(messageId) ;
- if (details != null)
- {
- return details ;
- }
- try
- {
- messageIdMap.wait(endTime - now) ;
- }
- catch (final InterruptedException ie) {} // ignore
- now = System.currentTimeMillis() ;
- }
- final ParticipantManagerParticipantDetails details = (ParticipantManagerParticipantDetails)messageIdMap.remove(messageId) ;
- if (details != null)
- {
- return details ;
- }
- }
- throw new NullPointerException("Timeout occurred waiting for id: " + messageId) ;
- }
-
- public void completed(NotificationType completed,
- AddressingContext addressingContext, ArjunaContext arjunaContext)
- {
- final String messageId = addressingContext.getMessageID().getValue() ;
- final ParticipantManagerParticipantDetails details = new ParticipantManagerParticipantDetails(addressingContext, arjunaContext) ;
- details.setCompleted(true) ;
-
- synchronized(messageIdMap)
- {
- messageIdMap.put(messageId, details) ;
- messageIdMap.notifyAll() ;
- }
- }
-
- public void exit(NotificationType exit,
- AddressingContext addressingContext, ArjunaContext arjunaContext)
- {
- final String messageId = addressingContext.getMessageID().getValue() ;
- final ParticipantManagerParticipantDetails details = new ParticipantManagerParticipantDetails(addressingContext, arjunaContext) ;
- details.setExit(true) ;
-
- synchronized(messageIdMap)
- {
- messageIdMap.put(messageId, details) ;
- messageIdMap.notifyAll() ;
- }
- }
-
- public void fault(NotificationType fault,
- AddressingContext addressingContext, ArjunaContext arjunaContext)
- {
- final String messageId = addressingContext.getMessageID().getValue() ;
- final ParticipantManagerParticipantDetails details = new ParticipantManagerParticipantDetails(addressingContext, arjunaContext) ;
- details.setFault(true) ;
-
- synchronized(messageIdMap)
- {
- messageIdMap.put(messageId, details) ;
- messageIdMap.notifyAll() ;
- }
- }
-
- public void soapFault(SoapFault soapFault, AddressingContext addressingContext,
- ArjunaContext arjunaContext)
- {
- final String messageId = addressingContext.getMessageID().getValue() ;
- final ParticipantManagerParticipantDetails details = new ParticipantManagerParticipantDetails(addressingContext, arjunaContext) ;
- details.setSoapFault(soapFault) ;
-
- synchronized(messageIdMap)
- {
- messageIdMap.put(messageId, details) ;
- messageIdMap.notifyAll() ;
- }
- }
-
- public void activateParticipant(BAParticipantManager participant,
- String identifier)
- {
- }
-
- public void deactivateParticipant(BAParticipantManager participant)
- {
- }
-
- public static class ParticipantManagerParticipantDetails
- {
- private final AddressingContext addressingContext ;
- private final ArjunaContext arjunaContext ;
- private boolean completed ;
- private boolean exit ;
- private boolean fault ;
- private SoapFault soapFault ;
-
- ParticipantManagerParticipantDetails(final AddressingContext addressingContext, final ArjunaContext arjunaContext)
- {
- this.addressingContext = addressingContext ;
- this.arjunaContext = arjunaContext ;
- }
-
- public AddressingContext getAddressingContext()
- {
- return addressingContext ;
- }
-
- public ArjunaContext getArjunaContext()
- {
- return arjunaContext ;
- }
-
- public boolean hasCompleted()
- {
- return completed ;
- }
-
- void setCompleted(final boolean completed)
- {
- this.completed = completed ;
- }
-
- public boolean hasExit()
- {
- return exit ;
- }
-
- void setExit(final boolean exit)
- {
- this.exit = exit ;
- }
-
- public boolean hasFault()
- {
- return fault ;
- }
-
- void setFault(final boolean fault)
- {
- this.fault = fault ;
- }
-
- public SoapFault getSoapFault()
- {
- return soapFault ;
- }
-
- void setSoapFault(final SoapFault soapFault)
- {
- this.soapFault = soapFault ;
- }
- }
-}
More information about the jboss-svn-commits
mailing list