You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@activemq.apache.org by ta...@apache.org on 2008/12/04 17:56:23 UTC
svn commit: r723374 [2/3] - in
/activemq/activemq-cpp/trunk/src/test-integration: ./ activemq/
activemq/test/ activemq/test/openwire/ activemq/test/stomp/ activemq/util/
integration/
Added: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireAsyncSenderTest.cpp
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireAsyncSenderTest.cpp?rev=723374&view=auto
==============================================================================
--- activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireAsyncSenderTest.cpp (added)
+++ activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireAsyncSenderTest.cpp Thu Dec 4 08:56:21 2008
@@ -0,0 +1,69 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#include "OpenwireAsyncSenderTest.h"
+
+#include <activemq/connector/openwire/OpenWireConnector.h>
+#include <activemq/core/ActiveMQConnectionFactory.h>
+#include <activemq/core/ActiveMQConnection.h>
+
+using namespace std;
+using namespace cms;
+using namespace activemq;
+using namespace activemq::test;
+using namespace activemq::test::openwire;
+using namespace activemq::core;
+using namespace activemq::connector;
+using namespace activemq::connector::openwire;
+using namespace activemq::util;
+
+////////////////////////////////////////////////////////////////////////////////
+OpenwireAsyncSenderTest::OpenwireAsyncSenderTest() {
+}
+
+////////////////////////////////////////////////////////////////////////////////
+OpenwireAsyncSenderTest::~OpenwireAsyncSenderTest() {
+}
+
+////////////////////////////////////////////////////////////////////////////////
+void OpenwireAsyncSenderTest::testOpenWireConnector() {
+
+ try{
+
+ auto_ptr<ActiveMQConnectionFactory> connectionFactory(
+ new ActiveMQConnectionFactory( this->getBrokerURL() ) );
+ auto_ptr<cms::Connection> connection( connectionFactory->createConnection() );
+
+ ActiveMQConnection* amqConnection =
+ dynamic_cast<ActiveMQConnection*>( connection.get() );
+ CPPUNIT_ASSERT( amqConnection != NULL );
+
+ OpenWireConnector* connector =
+ dynamic_cast<OpenWireConnector*>( amqConnection->getConnectionData()->getConnector() );
+ CPPUNIT_ASSERT( amqConnection != NULL );
+
+ CPPUNIT_ASSERT( connector->isUseAsyncSend() );
+ CPPUNIT_ASSERT( !connector->isAlwaysSyncSend() );
+
+ connection->start();
+ connection->stop();
+
+ CPPUNIT_ASSERT( true );
+ } catch(...) {
+ CPPUNIT_ASSERT( false );
+ }
+}
Added: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireAsyncSenderTest.h
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireAsyncSenderTest.h?rev=723374&view=auto
==============================================================================
--- activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireAsyncSenderTest.h (added)
+++ activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireAsyncSenderTest.h Thu Dec 4 08:56:21 2008
@@ -0,0 +1,51 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef _ACTIVEMQ_TEST_OPENWIRE_OPENWIREASYNCSENDERTEST_H_
+#define _ACTIVEMQ_TEST_OPENWIRE_OPENWIREASYNCSENDERTEST_H_
+
+#include <activemq/test/AsyncSenderTest.h>
+#include <activemq/util/IntegrationCommon.h>
+
+namespace activemq{
+namespace test{
+namespace openwire{
+
+ class OpenwireAsyncSenderTest : public AsyncSenderTest {
+
+ CPPUNIT_TEST_SUITE( OpenwireAsyncSenderTest );
+ CPPUNIT_TEST( testAsyncSends );
+ CPPUNIT_TEST( testOpenWireConnector );
+ CPPUNIT_TEST_SUITE_END();
+
+ public:
+
+ OpenwireAsyncSenderTest();
+ virtual ~OpenwireAsyncSenderTest();
+
+ virtual std::string getBrokerURL() const {
+ return activemq::util::IntegrationCommon::getInstance().getOpenwireURL() +
+ "&connection.useAsyncSend=true";
+ }
+
+ virtual void testOpenWireConnector();
+
+ };
+
+}}}
+
+#endif /*_ACTIVEMQ_TEST_OPENWIRE_OPENWIREASYNCSENDERTEST_H_*/
Propchange: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireAsyncSenderTest.h
------------------------------------------------------------------------------
svn:eol-style = native
Added: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireCmsTemplateTest.cpp
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireCmsTemplateTest.cpp?rev=723374&view=auto
==============================================================================
--- activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireCmsTemplateTest.cpp (added)
+++ activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireCmsTemplateTest.cpp Thu Dec 4 08:56:21 2008
@@ -0,0 +1,30 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#include "OpenwireCmsTemplateTest.h"
+
+using namespace activemq;
+using namespace activemq::test;
+using namespace activemq::test::openwire;
+
+////////////////////////////////////////////////////////////////////////////////
+OpenwireCmsTemplateTest::OpenwireCmsTemplateTest() {
+}
+
+////////////////////////////////////////////////////////////////////////////////
+OpenwireCmsTemplateTest::~OpenwireCmsTemplateTest() {
+}
Propchange: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireCmsTemplateTest.cpp
------------------------------------------------------------------------------
svn:eol-style = native
Added: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireCmsTemplateTest.h
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireCmsTemplateTest.h?rev=723374&view=auto
==============================================================================
--- activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireCmsTemplateTest.h (added)
+++ activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireCmsTemplateTest.h Thu Dec 4 08:56:21 2008
@@ -0,0 +1,49 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef _ACTIVEMQ_TEST_OPENWIRE_OPENWIRECMSTEMPLATETEST_H_
+#define _ACTIVEMQ_TEST_OPENWIRE_OPENWIRECMSTEMPLATETEST_H_
+
+#include <activemq/test/CmsTemplateTest.h>
+#include <activemq/util/IntegrationCommon.h>
+
+namespace activemq{
+namespace test{
+namespace openwire{
+
+ class OpenwireCmsTemplateTest : public CmsTemplateTest {
+
+ CPPUNIT_TEST_SUITE( OpenwireCmsTemplateTest );
+ CPPUNIT_TEST( testBasics );
+ CPPUNIT_TEST( testReceiveException );
+ CPPUNIT_TEST( testSendException );
+ CPPUNIT_TEST_SUITE_END();
+
+ public:
+
+ OpenwireCmsTemplateTest();
+ virtual ~OpenwireCmsTemplateTest();
+
+ virtual std::string getBrokerURL() const {
+ return activemq::util::IntegrationCommon::getInstance().getOpenwireURL();
+ }
+
+ };
+
+}}}
+
+#endif /*_ACTIVEMQ_TEST_OPENWIRE_OPENWIRECMSTEMPLATETEST_H_*/
Propchange: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireCmsTemplateTest.h
------------------------------------------------------------------------------
svn:eol-style = native
Added: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireDurableTest.cpp
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireDurableTest.cpp?rev=723374&view=auto
==============================================================================
--- activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireDurableTest.cpp (added)
+++ activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireDurableTest.cpp Thu Dec 4 08:56:21 2008
@@ -0,0 +1,30 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#include "OpenwireDurableTest.h"
+
+using namespace activemq;
+using namespace activemq::test;
+using namespace activemq::test::openwire;
+
+////////////////////////////////////////////////////////////////////////////////
+OpenwireDurableTest::OpenwireDurableTest() {
+}
+
+////////////////////////////////////////////////////////////////////////////////
+OpenwireDurableTest::~OpenwireDurableTest() {
+}
Propchange: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireDurableTest.cpp
------------------------------------------------------------------------------
svn:eol-style = native
Added: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireDurableTest.h
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireDurableTest.h?rev=723374&view=auto
==============================================================================
--- activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireDurableTest.h (added)
+++ activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireDurableTest.h Thu Dec 4 08:56:21 2008
@@ -0,0 +1,46 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef _ACTIVEMQ_TEST_OPENWIRE_OPENWIREDURABLETESTER_H_
+#define _ACTIVEMQ_TEST_OPENWIRE_OPENWIREDURABLETESTER_H_
+
+#include <activemq/test/DurableTest.h>
+
+namespace activemq{
+namespace test{
+namespace openwire{
+
+ class OpenwireDurableTest : public DurableTest {
+
+ CPPUNIT_TEST_SUITE( OpenwireDurableTest );
+ CPPUNIT_TEST( testDurableConsumer );
+ CPPUNIT_TEST_SUITE_END();
+
+ public:
+
+ OpenwireDurableTest();
+ virtual ~OpenwireDurableTest();
+
+ virtual std::string getBrokerURL() const {
+ return activemq::util::IntegrationCommon::getInstance().getOpenwireURL();
+ }
+
+ };
+
+}}}
+
+#endif /*_ACTIVEMQ_TEST_OPENWIRE_OPENWIREDURABLETESTER_H_*/
Propchange: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireDurableTest.h
------------------------------------------------------------------------------
svn:eol-style = native
Added: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireExpirationTest.cpp
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireExpirationTest.cpp?rev=723374&view=auto
==============================================================================
--- activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireExpirationTest.cpp (added)
+++ activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireExpirationTest.cpp Thu Dec 4 08:56:21 2008
@@ -0,0 +1,32 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#include "OpenwireExpirationTest.h"
+
+using namespace std;
+using namespace cms;
+using namespace activemq;
+using namespace activemq::test;
+using namespace activemq::test::openwire;
+
+////////////////////////////////////////////////////////////////////////////////
+OpenwireExpirationTest::OpenwireExpirationTest() {
+}
+
+////////////////////////////////////////////////////////////////////////////////
+OpenwireExpirationTest::~OpenwireExpirationTest() {
+}
Propchange: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireExpirationTest.cpp
------------------------------------------------------------------------------
svn:eol-style = native
Added: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireExpirationTest.h
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireExpirationTest.h?rev=723374&view=auto
==============================================================================
--- activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireExpirationTest.h (added)
+++ activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireExpirationTest.h Thu Dec 4 08:56:21 2008
@@ -0,0 +1,47 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef _ACTIVEMQ_TEST_OPENWIRE_OPENWIREEXPIRATIONTEST_H_
+#define _ACTIVEMQ_TEST_OPENWIRE_OPENWIREEXPIRATIONTEST_H_
+
+#include <activemq/test/ExpirationTest.h>
+
+namespace activemq{
+namespace test{
+namespace openwire{
+
+ class OpenwireExpirationTest : public ExpirationTest {
+
+ CPPUNIT_TEST_SUITE( OpenwireExpirationTest );
+ CPPUNIT_TEST( testExpired );
+ CPPUNIT_TEST( testNotExpired );
+ CPPUNIT_TEST_SUITE_END();
+
+ public:
+
+ OpenwireExpirationTest();
+ virtual ~OpenwireExpirationTest();
+
+ virtual std::string getBrokerURL() const {
+ return activemq::util::IntegrationCommon::getInstance().getOpenwireURL();
+ }
+
+ };
+
+}}}
+
+#endif /*_ACTIVEMQ_TEST_OPENWIRE_OPENWIREEXPIRATIONTEST_H_*/
Propchange: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireExpirationTest.h
------------------------------------------------------------------------------
svn:eol-style = native
Added: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireSimpleRollbackTest.cpp
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireSimpleRollbackTest.cpp?rev=723374&view=auto
==============================================================================
--- activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireSimpleRollbackTest.cpp (added)
+++ activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireSimpleRollbackTest.cpp Thu Dec 4 08:56:21 2008
@@ -0,0 +1,32 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#include "OpenwireSimpleRollbackTest.h"
+
+using namespace std;
+using namespace cms;
+using namespace activemq;
+using namespace activemq::test;
+using namespace activemq::test::openwire;
+
+////////////////////////////////////////////////////////////////////////////////
+OpenwireSimpleRollbackTest::OpenwireSimpleRollbackTest() {
+}
+
+////////////////////////////////////////////////////////////////////////////////
+OpenwireSimpleRollbackTest::~OpenwireSimpleRollbackTest() {
+}
Propchange: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireSimpleRollbackTest.cpp
------------------------------------------------------------------------------
svn:eol-style = native
Added: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireSimpleRollbackTest.h
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireSimpleRollbackTest.h?rev=723374&view=auto
==============================================================================
--- activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireSimpleRollbackTest.h (added)
+++ activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireSimpleRollbackTest.h Thu Dec 4 08:56:21 2008
@@ -0,0 +1,46 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef _ACTIVEMQ_TEST_OPENWIRE_OPENWIRESIMPLEROLLBACKTEST_H_
+#define _ACTIVEMQ_TEST_OPENWIRE_OPENWIRESIMPLEROLLBACKTEST_H_
+
+#include <activemq/test/SimpleRollbackTest.h>
+
+namespace activemq{
+namespace test{
+namespace openwire{
+
+ class OpenwireSimpleRollbackTest : public SimpleRollbackTest {
+
+ CPPUNIT_TEST_SUITE( OpenwireSimpleRollbackTest );
+ CPPUNIT_TEST( testRollbacks );
+ CPPUNIT_TEST_SUITE_END();
+
+ public:
+
+ OpenwireSimpleRollbackTest();
+ virtual ~OpenwireSimpleRollbackTest();
+
+ virtual std::string getBrokerURL() const {
+ return activemq::util::IntegrationCommon::getInstance().getOpenwireURL();
+ }
+
+ };
+
+}}}
+
+#endif /*_ACTIVEMQ_TEST_OPENWIRE_OPENWIRESIMPLEROLLBACKTEST_H_*/
Propchange: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireSimpleRollbackTest.h
------------------------------------------------------------------------------
svn:eol-style = native
Added: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireSimpleTest.cpp
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireSimpleTest.cpp?rev=723374&view=auto
==============================================================================
--- activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireSimpleTest.cpp (added)
+++ activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireSimpleTest.cpp Thu Dec 4 08:56:21 2008
@@ -0,0 +1,204 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#include "OpenwireSimpleTest.h"
+
+#include <activemq/util/CMSListener.h>
+#include <activemq/exceptions/ActiveMQException.h>
+
+#include <decaf/util/UUID.h>
+
+using namespace std;
+using namespace cms;
+using namespace activemq;
+using namespace activemq::test;
+using namespace activemq::test::openwire;
+using namespace activemq::util;
+using namespace activemq::exceptions;
+using namespace decaf;
+using namespace decaf::util;
+
+////////////////////////////////////////////////////////////////////////////////
+OpenwireSimpleTest::OpenwireSimpleTest() {
+}
+
+////////////////////////////////////////////////////////////////////////////////
+OpenwireSimpleTest::~OpenwireSimpleTest() {
+}
+
+////////////////////////////////////////////////////////////////////////////////
+void OpenwireSimpleTest::testWithZeroConsumerPrefetch() {
+
+ try {
+
+ cmsProvider->setTopic( false );
+ cmsProvider->setDestinationName(
+ UUID::randomUUID().toString() + "?consumer.prefetchSize=0" );
+
+ cmsProvider->reconnectSession();
+
+ // Create CMS Object for Comms
+ cms::Session* session( cmsProvider->getSession() );
+ cms::MessageConsumer* consumer = cmsProvider->getConsumer();
+ cms::MessageProducer* producer = cmsProvider->getProducer();
+ producer->setDeliveryMode( DeliveryMode::NON_PERSISTENT );
+
+ auto_ptr<cms::TextMessage> txtMessage( session->createTextMessage( "TEST MESSAGE" ) );
+
+ // Send some text messages
+ producer->send( txtMessage.get() );
+
+ auto_ptr<cms::Message> message( consumer->receive( 1000 ) );
+ CPPUNIT_ASSERT( message.get() != NULL );
+ }
+ AMQ_CATCH_RETHROW( ActiveMQException )
+ AMQ_CATCHALL_THROW( ActiveMQException )
+}
+
+////////////////////////////////////////////////////////////////////////////////
+void OpenwireSimpleTest::testMapMessageSendToQueue() {
+
+ try {
+
+ cmsProvider->setTopic( false );
+ cmsProvider->setDestinationName(
+ UUID::randomUUID().toString() + "?consumer.prefetchSize=0" );
+
+ cmsProvider->reconnectSession();
+
+ // Create CMS Object for Comms
+ cms::Session* session( cmsProvider->getSession() );
+ cms::MessageConsumer* consumer = cmsProvider->getConsumer();
+ cms::MessageProducer* producer = cmsProvider->getProducer();
+ producer->setDeliveryMode( DeliveryMode::NON_PERSISTENT );
+
+ unsigned char byteValue = 'A';
+ char charValue = 'B';
+ bool booleanValue = true;
+ short shortValue = 2048;
+ int intValue = 655369;
+ long long longValue = 0xFFFFFFFF00000000ULL;
+ float floatValue = 45.6545f;
+ double doubleValue = 654564.654654;
+ std::string stringValue = "The test string";
+
+ auto_ptr<cms::MapMessage> mapMessage( session->createMapMessage() );
+
+ mapMessage->setString( "stringKey", stringValue );
+ mapMessage->setBoolean( "boolKey", booleanValue );
+ mapMessage->setByte( "byteKey", byteValue );
+ mapMessage->setChar( "charKey", charValue );
+ mapMessage->setShort( "shortKey", shortValue );
+ mapMessage->setInt( "intKey", intValue );
+ mapMessage->setLong( "longKey", longValue );
+ mapMessage->setFloat( "floatKey", floatValue );
+ mapMessage->setDouble( "doubleKey", doubleValue );
+
+ std::vector<unsigned char> bytes;
+ bytes.push_back( 65 );
+ bytes.push_back( 66 );
+ bytes.push_back( 67 );
+ bytes.push_back( 68 );
+ bytes.push_back( 69 );
+ mapMessage->setBytes( "bytesKey", bytes );
+
+ // Send some text messages
+ producer->send( mapMessage.get() );
+
+ auto_ptr<cms::Message> message( consumer->receive( 2000 ) );
+ CPPUNIT_ASSERT( message.get() != NULL );
+
+ cms::MapMessage* recvMapMessage = dynamic_cast<MapMessage*>( message.get() );
+ CPPUNIT_ASSERT( recvMapMessage != NULL );
+ CPPUNIT_ASSERT( recvMapMessage->getString( "stringKey" ) == stringValue );
+ CPPUNIT_ASSERT( recvMapMessage->getBoolean( "boolKey" ) == booleanValue );
+ CPPUNIT_ASSERT( recvMapMessage->getByte( "byteKey" ) == byteValue );
+ CPPUNIT_ASSERT( recvMapMessage->getChar( "charKey" ) == charValue );
+ CPPUNIT_ASSERT( recvMapMessage->getShort( "shortKey" ) == shortValue );
+ CPPUNIT_ASSERT( recvMapMessage->getInt( "intKey" ) == intValue );
+ CPPUNIT_ASSERT( recvMapMessage->getLong( "longKey" ) == longValue );
+ CPPUNIT_ASSERT( recvMapMessage->getFloat( "floatKey" ) == floatValue );
+ CPPUNIT_ASSERT( recvMapMessage->getDouble( "doubleKey" ) == doubleValue );
+ CPPUNIT_ASSERT( recvMapMessage->getBytes( "bytesKey" ) == bytes );
+ }
+ AMQ_CATCH_RETHROW( ActiveMQException )
+ AMQ_CATCHALL_THROW( ActiveMQException )
+}
+
+////////////////////////////////////////////////////////////////////////////////
+void OpenwireSimpleTest::testMapMessageSendToTopic() {
+
+ try {
+
+ // Create CMS Object for Comms
+ cms::Session* session( cmsProvider->getSession() );
+ cms::MessageConsumer* consumer = cmsProvider->getConsumer();
+ cms::MessageProducer* producer = cmsProvider->getProducer();
+ producer->setDeliveryMode( DeliveryMode::NON_PERSISTENT );
+
+ unsigned char byteValue = 'A';
+ char charValue = 'B';
+ bool booleanValue = true;
+ short shortValue = 2048;
+ int intValue = 655369;
+ long long longValue = 0xFFFFFFFF00000000ULL;
+ float floatValue = 45.6545f;
+ double doubleValue = 654564.654654;
+ std::string stringValue = "The test string";
+
+ auto_ptr<cms::MapMessage> mapMessage( session->createMapMessage() );
+
+ mapMessage->setString( "stringKey", stringValue );
+ mapMessage->setBoolean( "boolKey", booleanValue );
+ mapMessage->setByte( "byteKey", byteValue );
+ mapMessage->setChar( "charKey", charValue );
+ mapMessage->setShort( "shortKey", shortValue );
+ mapMessage->setInt( "intKey", intValue );
+ mapMessage->setLong( "longKey", longValue );
+ mapMessage->setFloat( "floatKey", floatValue );
+ mapMessage->setDouble( "doubleKey", doubleValue );
+
+ std::vector<unsigned char> bytes;
+ bytes.push_back( 65 );
+ bytes.push_back( 66 );
+ bytes.push_back( 67 );
+ bytes.push_back( 68 );
+ bytes.push_back( 69 );
+ mapMessage->setBytes( "bytesKey", bytes );
+
+ // Send some text messages
+ producer->send( mapMessage.get() );
+
+ auto_ptr<cms::Message> message( consumer->receive( 2000 ) );
+ CPPUNIT_ASSERT( message.get() != NULL );
+
+ cms::MapMessage* recvMapMessage = dynamic_cast<MapMessage*>( message.get() );
+ CPPUNIT_ASSERT( recvMapMessage != NULL );
+ CPPUNIT_ASSERT( recvMapMessage->getString( "stringKey" ) == stringValue );
+ CPPUNIT_ASSERT( recvMapMessage->getBoolean( "boolKey" ) == booleanValue );
+ CPPUNIT_ASSERT( recvMapMessage->getByte( "byteKey" ) == byteValue );
+ CPPUNIT_ASSERT( recvMapMessage->getChar( "charKey" ) == charValue );
+ CPPUNIT_ASSERT( recvMapMessage->getShort( "shortKey" ) == shortValue );
+ CPPUNIT_ASSERT( recvMapMessage->getInt( "intKey" ) == intValue );
+ CPPUNIT_ASSERT( recvMapMessage->getLong( "longKey" ) == longValue );
+ CPPUNIT_ASSERT( recvMapMessage->getFloat( "floatKey" ) == floatValue );
+ CPPUNIT_ASSERT( recvMapMessage->getDouble( "doubleKey" ) == doubleValue );
+ CPPUNIT_ASSERT( recvMapMessage->getBytes( "bytesKey" ) == bytes );
+ }
+ AMQ_CATCH_RETHROW( ActiveMQException )
+ AMQ_CATCHALL_THROW( ActiveMQException )
+}
Propchange: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireSimpleTest.cpp
------------------------------------------------------------------------------
svn:eol-style = native
Added: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireSimpleTest.h
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireSimpleTest.h?rev=723374&view=auto
==============================================================================
--- activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireSimpleTest.h (added)
+++ activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireSimpleTest.h Thu Dec 4 08:56:21 2008
@@ -0,0 +1,61 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef _ACTIVEMQ_TEST_OPENWIRE_OPENWIRESIMPLETEST_H_
+#define _ACTIVEMQ_TEST_OPENWIRE_OPENWIRESIMPLETEST_H_
+
+#include <activemq/test/SimpleTest.h>
+
+namespace activemq{
+namespace test{
+namespace openwire{
+
+ class OpenwireSimpleTest : public SimpleTest {
+
+ CPPUNIT_TEST_SUITE( OpenwireSimpleTest );
+ CPPUNIT_TEST( testAutoAck );
+ CPPUNIT_TEST( testClientAck );
+ CPPUNIT_TEST( testProducerWithNullDestination );
+ CPPUNIT_TEST( testSyncReceive );
+ CPPUNIT_TEST( testSyncReceiveClientAck );
+ CPPUNIT_TEST( testMultipleConnections );
+ CPPUNIT_TEST( testMultipleSessions );
+ CPPUNIT_TEST( testReceiveAlreadyInQueue );
+ CPPUNIT_TEST( testQuickCreateAndDestroy );
+ CPPUNIT_TEST( testWithZeroConsumerPrefetch );
+ CPPUNIT_TEST( testMapMessageSendToQueue );
+ CPPUNIT_TEST( testMapMessageSendToTopic );
+ CPPUNIT_TEST_SUITE_END();
+
+ public:
+
+ OpenwireSimpleTest();
+ virtual ~OpenwireSimpleTest();
+
+ virtual std::string getBrokerURL() const {
+ return activemq::util::IntegrationCommon::getInstance().getOpenwireURL();
+ }
+
+ virtual void testWithZeroConsumerPrefetch();
+ virtual void testMapMessageSendToQueue();
+ virtual void testMapMessageSendToTopic();
+
+ };
+
+}}}
+
+#endif /*_ACTIVEMQ_TEST_OPENWIRE_OPENWIRESIMPLETEST_H_*/
Propchange: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireSimpleTest.h
------------------------------------------------------------------------------
svn:eol-style = native
Added: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireSlowListenerTest.cpp
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireSlowListenerTest.cpp?rev=723374&view=auto
==============================================================================
--- activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireSlowListenerTest.cpp (added)
+++ activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireSlowListenerTest.cpp Thu Dec 4 08:56:21 2008
@@ -0,0 +1,33 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#include "OpenwireSlowListenerTest.h"
+
+using namespace std;
+using namespace cms;
+using namespace activemq;
+using namespace activemq::test;
+using namespace activemq::test::openwire;
+using namespace activemq::util;
+
+////////////////////////////////////////////////////////////////////////////////
+OpenwireSlowListenerTest::OpenwireSlowListenerTest() {
+}
+
+////////////////////////////////////////////////////////////////////////////////
+OpenwireSlowListenerTest::~OpenwireSlowListenerTest() {
+}
Propchange: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireSlowListenerTest.cpp
------------------------------------------------------------------------------
svn:eol-style = native
Added: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireSlowListenerTest.h
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireSlowListenerTest.h?rev=723374&view=auto
==============================================================================
--- activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireSlowListenerTest.h (added)
+++ activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireSlowListenerTest.h Thu Dec 4 08:56:21 2008
@@ -0,0 +1,46 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef _ACTIVEMQ_TEST_OPENWIRE_OPENWIRESLOWLISTENERTEST_H_
+#define _ACTIVEMQ_TEST_OPENWIRE_OPENWIRESLOWLISTENERTEST_H_
+
+#include <activemq/test/SlowListenerTest.h>
+
+namespace activemq{
+namespace test{
+namespace openwire{
+
+ class OpenwireSlowListenerTest : public SlowListenerTest {
+
+ CPPUNIT_TEST_SUITE( OpenwireSlowListenerTest );
+ CPPUNIT_TEST( testSlowListener );
+ CPPUNIT_TEST_SUITE_END();
+
+ public:
+
+ OpenwireSlowListenerTest();
+ virtual ~OpenwireSlowListenerTest();
+
+ virtual std::string getBrokerURL() const {
+ return activemq::util::IntegrationCommon::getInstance().getOpenwireURL();
+ }
+
+ };
+
+}}}
+
+#endif /*_ACTIVEMQ_TEST_OPENWIRE_OPENWIRESLOWLISTENERTEST_H_*/
Propchange: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireSlowListenerTest.h
------------------------------------------------------------------------------
svn:eol-style = native
Added: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireTempDestinationTest.cpp
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireTempDestinationTest.cpp?rev=723374&view=auto
==============================================================================
--- activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireTempDestinationTest.cpp (added)
+++ activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireTempDestinationTest.cpp Thu Dec 4 08:56:21 2008
@@ -0,0 +1,241 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#include "OpenwireTempDestinationTest.h"
+
+#include <decaf/lang/Thread.h>
+#include <decaf/util/concurrent/Mutex.h>
+#include <decaf/util/concurrent/CountDownLatch.h>
+#include <decaf/util/UUID.h>
+#include <activemq/exceptions/ActiveMQException.h>
+
+using namespace std;
+using namespace cms;
+using namespace activemq;
+using namespace activemq::test;
+using namespace activemq::test::openwire;
+using namespace activemq::util;
+using namespace activemq::exceptions;
+using namespace decaf;
+using namespace decaf::util;
+using namespace decaf::util::concurrent;
+using namespace decaf::lang;
+
+namespace activemq{
+namespace test{
+namespace openwire{
+
+ class Requester : public cms::MessageListener,
+ public decaf::lang::Runnable {
+ private:
+
+ auto_ptr<CMSProvider> cmsProvider;
+ auto_ptr<cms::MessageConsumer> tempTopicConsumer;
+
+ unsigned int numReceived;
+ unsigned int messageCount;
+
+ decaf::util::concurrent::CountDownLatch ready;
+ decaf::util::concurrent::CountDownLatch responses;
+
+ public:
+
+ Requester( const std::string& url,
+ const std::string& destination,
+ unsigned int messageCount )
+ : messageCount( messageCount ), ready( 1 ), responses( messageCount ) {
+
+ this->cmsProvider.reset( new CMSProvider( url ) );
+ this->cmsProvider->setDestinationName( destination );
+
+ this->cmsProvider->getProducer()->setDeliveryMode( DeliveryMode::NON_PERSISTENT );
+
+ this->tempTopicConsumer.reset(
+ cmsProvider->getSession()->createConsumer(
+ cmsProvider->getTempDestination() ) );
+ this->tempTopicConsumer->setMessageListener( this );
+
+ this->numReceived = 0;
+ }
+
+ virtual ~Requester() {}
+
+ virtual unsigned int getNumReceived() const {
+ return this->numReceived;
+ }
+
+ virtual void waitUnitReady() {
+ this->ready.await();
+ }
+
+ virtual void awaitAllResponses() {
+ this->responses.await( 2000 * this->messageCount );
+ }
+
+ virtual void run() {
+
+ try {
+
+ auto_ptr<cms::TextMessage> message(
+ this->cmsProvider->getSession()->createTextMessage() );
+ message->setCMSReplyTo( this->cmsProvider->getTempDestination() );
+
+ this->ready.countDown();
+
+ for( unsigned int i = 0; i < messageCount; ++i ) {
+ this->cmsProvider->getProducer()->send( message.get() );
+ }
+
+ } catch( CMSException& e ) {
+ e.printStackTrace();
+ }
+ }
+
+ virtual void onMessage( const cms::Message* message ) {
+
+ try {
+
+ this->numReceived++;
+ this->responses.countDown();
+
+ } catch( CMSException& e ) {
+ e.printStackTrace();
+ }
+ }
+ };
+
+ class Responder : public cms::MessageListener {
+ private:
+
+ auto_ptr<CMSProvider> cmsProvider;
+
+ unsigned int numReceived;
+ unsigned int messageCount;
+
+ decaf::util::concurrent::CountDownLatch requests;
+
+ public:
+
+ Responder( const std::string& url,
+ const std::string& destination,
+ unsigned int messageCount )
+ : messageCount( messageCount ), requests( messageCount ) {
+
+ this->cmsProvider.reset( new CMSProvider( url ) );
+
+ this->cmsProvider->setDestinationName( destination );
+ this->cmsProvider->getNoDestProducer()->setDeliveryMode(
+ DeliveryMode::NON_PERSISTENT );
+ this->cmsProvider->getConsumer()->setMessageListener( this );
+
+ this->numReceived = 0;
+ }
+
+ virtual ~Responder() {}
+
+ virtual unsigned int getNumReceived() const {
+ return this->numReceived;
+ }
+
+ virtual void awaitAllRequests() {
+ this->requests.await( 2000 * this->messageCount );
+ }
+
+ virtual void onMessage( const cms::Message* message ) {
+
+ try {
+
+ if( message->getCMSReplyTo() != NULL ) {
+
+ auto_ptr<cms::Message> response(
+ cmsProvider->getSession()->createMessage() );
+
+ // Send it back to the replyTo Destination
+ this->cmsProvider->getNoDestProducer()->send(
+ message->getCMSReplyTo(), response.get() );
+
+ this->requests.countDown();
+ }
+
+ this->numReceived++;
+
+ } catch( CMSException& e ) {
+ e.printStackTrace();
+ }
+ }
+ };
+
+}}}
+
+///////////////////////////////////////////////////////////////////////////////
+void OpenwireTempDestinationTest::testBasics() {
+
+ try{
+
+ auto_ptr<cms::MessageConsumer> tempConsumer(
+ cmsProvider->getSession()->createConsumer(
+ cmsProvider->getTempDestination() ) );
+
+ auto_ptr<TextMessage> message(
+ cmsProvider->getSession()->createTextMessage() );
+
+ // Fire a message to the temporary topic
+ cmsProvider->getNoDestProducer()->send(
+ cmsProvider->getTempDestination(), message.get() );
+
+ auto_ptr<cms::Message> received( tempConsumer->receive( 3000 ) );
+
+ CPPUNIT_ASSERT( received.get() != NULL );
+ }
+ AMQ_CATCH_RETHROW( ActiveMQException )
+ AMQ_CATCHALL_THROW( ActiveMQException )
+}
+
+///////////////////////////////////////////////////////////////////////////////
+void OpenwireTempDestinationTest::testTwoConnections() {
+
+ try {
+
+ std::string destination = "REQUEST-TOPIC";
+
+ auto_ptr<Requester> requester(
+ new Requester( cmsProvider->getBrokerURL(), destination, 10 ) );
+ auto_ptr<Responder> responder(
+ new Responder( cmsProvider->getBrokerURL(), destination, 10 ) );
+
+ // Launch the Consumers in new Threads.
+ Thread requestorThread( requester.get() );
+ requestorThread.start();
+
+ // Responder should get all its requests first
+ responder->awaitAllRequests();
+
+ // Now the Requester should get all its responses.
+ requester->awaitAllResponses();
+
+ // Check that the responder received all the required requests
+ CPPUNIT_ASSERT( responder->getNumReceived() == 10 );
+
+ // Check that the requester received all the required responses
+ CPPUNIT_ASSERT( requester->getNumReceived() == 10 );
+
+ // Shutdown the Requester.
+ requestorThread.join();
+ }
+ AMQ_CATCH_RETHROW( ActiveMQException )
+ AMQ_CATCHALL_THROW( ActiveMQException )
+}
Propchange: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireTempDestinationTest.cpp
------------------------------------------------------------------------------
svn:eol-style = native
Added: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireTempDestinationTest.h
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireTempDestinationTest.h?rev=723374&view=auto
==============================================================================
--- activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireTempDestinationTest.h (added)
+++ activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireTempDestinationTest.h Thu Dec 4 08:56:21 2008
@@ -0,0 +1,50 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef _ACTIVEMQ_TEST_OPENWIRE_OPENWIRETEMPDESTINATIONTEST_H_
+#define _ACTIVEMQ_TEST_OPENWIRE_OPENWIRETEMPDESTINATIONTEST_H_
+
+#include <activemq/test/CMSTestFixture.h>
+
+namespace activemq{
+namespace test{
+namespace openwire{
+
+ class OpenwireTempDestinationTest : public CMSTestFixture {
+
+ CPPUNIT_TEST_SUITE( OpenwireTempDestinationTest );
+ CPPUNIT_TEST( testBasics );
+ CPPUNIT_TEST( testTwoConnections );
+ CPPUNIT_TEST_SUITE_END();
+
+ public:
+
+ OpenwireTempDestinationTest() {}
+ virtual ~OpenwireTempDestinationTest() {}
+
+ virtual void testBasics();
+ virtual void testTwoConnections();
+
+ virtual std::string getBrokerURL() const {
+ return activemq::util::IntegrationCommon::getInstance().getOpenwireURL();
+ }
+
+ };
+
+}}}
+
+#endif /*_ACTIVEMQ_TEST_OPENWIRE_OPENWIRETEMPDESTINATIONTEST_H_*/
Propchange: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireTempDestinationTest.h
------------------------------------------------------------------------------
svn:eol-style = native
Added: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireTransactionTest.cpp
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireTransactionTest.cpp?rev=723374&view=auto
==============================================================================
--- activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireTransactionTest.cpp (added)
+++ activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireTransactionTest.cpp Thu Dec 4 08:56:21 2008
@@ -0,0 +1,32 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#include "OpenwireTransactionTest.h"
+
+using namespace std;
+using namespace cms;
+using namespace activemq;
+using namespace activemq::test;
+using namespace activemq::test::openwire;
+
+////////////////////////////////////////////////////////////////////////////////
+OpenwireTransactionTest::OpenwireTransactionTest() {
+}
+
+////////////////////////////////////////////////////////////////////////////////
+OpenwireTransactionTest::~OpenwireTransactionTest() {
+}
Propchange: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireTransactionTest.cpp
------------------------------------------------------------------------------
svn:eol-style = native
Added: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireTransactionTest.h
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireTransactionTest.h?rev=723374&view=auto
==============================================================================
--- activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireTransactionTest.h (added)
+++ activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireTransactionTest.h Thu Dec 4 08:56:21 2008
@@ -0,0 +1,48 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef _ACTIVEMQ_TEST_OPENWIRE_OPENWIRETRANSACTIONTESTER_H_
+#define _ACTIVEMQ_TEST_OPENWIRE_OPENWIRETRANSACTIONTESTER_H_
+
+#include <activemq/test/TransactionTest.h>
+
+namespace activemq{
+namespace test{
+namespace openwire{
+
+ class OpenwireTransactionTest : public TransactionTest {
+
+ CPPUNIT_TEST_SUITE( OpenwireTransactionTest );
+ CPPUNIT_TEST( testSendReceiveTransactedBatches );
+ CPPUNIT_TEST( testSendRollback );
+// CPPUNIT_TEST( testSendSessionClose );
+ CPPUNIT_TEST_SUITE_END();
+
+ public:
+
+ OpenwireTransactionTest();
+ virtual ~OpenwireTransactionTest();
+
+ virtual std::string getBrokerURL() const {
+ return activemq::util::IntegrationCommon::getInstance().getOpenwireURL();
+ }
+
+ };
+
+}}}
+
+#endif /*_ACTIVEMQ_TEST_OPENWIRE_OPENWIRETRANSACTIONTESTER_H_*/
Propchange: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/openwire/OpenwireTransactionTest.h
------------------------------------------------------------------------------
svn:eol-style = native
Added: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompAsyncSenderTest.cpp
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompAsyncSenderTest.cpp?rev=723374&view=auto
==============================================================================
--- activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompAsyncSenderTest.cpp (added)
+++ activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompAsyncSenderTest.cpp Thu Dec 4 08:56:21 2008
@@ -0,0 +1,32 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#include "StompAsyncSenderTest.h"
+
+using namespace activemq::test::stomp;
+using namespace activemq::test;
+using namespace activemq;
+using namespace std;
+using namespace cms;
+
+////////////////////////////////////////////////////////////////////////////////
+StompAsyncSenderTest::StompAsyncSenderTest() {
+}
+
+////////////////////////////////////////////////////////////////////////////////
+StompAsyncSenderTest::~StompAsyncSenderTest() {
+}
Propchange: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompAsyncSenderTest.cpp
------------------------------------------------------------------------------
svn:eol-style = native
Added: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompAsyncSenderTest.h
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompAsyncSenderTest.h?rev=723374&view=auto
==============================================================================
--- activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompAsyncSenderTest.h (added)
+++ activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompAsyncSenderTest.h Thu Dec 4 08:56:21 2008
@@ -0,0 +1,48 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef _INTEGRATION_CONNECTOR_STOMP_STOMPASYNCSENDERTEST_H_
+#define _INTEGRATION_CONNECTOR_STOMP_STOMPASYNCSENDERTEST_H_
+
+#include <activemq/test/AsyncSenderTest.h>
+#include <activemq/util/IntegrationCommon.h>
+
+namespace activemq{
+namespace test{
+namespace stomp{
+
+ class StompAsyncSenderTest : public AsyncSenderTest {
+
+ CPPUNIT_TEST_SUITE( StompAsyncSenderTest );
+ CPPUNIT_TEST( testAsyncSends );
+ CPPUNIT_TEST_SUITE_END();
+
+ public:
+
+ StompAsyncSenderTest();
+ virtual ~StompAsyncSenderTest();
+
+ virtual std::string getBrokerURL() const {
+ return activemq::util::IntegrationCommon::getInstance().getStompURL() +
+ "&connection.useAsyncSend=true";
+ }
+
+ };
+
+}}}
+
+#endif /*_INTEGRATION_CONNECTOR_STOMP_STOMPASYNCSENDERTEST_H_*/
Propchange: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompAsyncSenderTest.h
------------------------------------------------------------------------------
svn:eol-style = native
Added: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompCmsTemplateTest.cpp
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompCmsTemplateTest.cpp?rev=723374&view=auto
==============================================================================
--- activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompCmsTemplateTest.cpp (added)
+++ activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompCmsTemplateTest.cpp Thu Dec 4 08:56:21 2008
@@ -0,0 +1,30 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#include "StompCmsTemplateTest.h"
+
+using namespace activemq;
+using namespace activemq::test;
+using namespace activemq::test::stomp;
+
+////////////////////////////////////////////////////////////////////////////////
+StompCmsTemplateTest::StompCmsTemplateTest() {
+}
+
+////////////////////////////////////////////////////////////////////////////////
+StompCmsTemplateTest::~StompCmsTemplateTest() {
+}
Propchange: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompCmsTemplateTest.cpp
------------------------------------------------------------------------------
svn:eol-style = native
Added: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompCmsTemplateTest.h
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompCmsTemplateTest.h?rev=723374&view=auto
==============================================================================
--- activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompCmsTemplateTest.h (added)
+++ activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompCmsTemplateTest.h Thu Dec 4 08:56:21 2008
@@ -0,0 +1,49 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef _INTEGRATION_CONNECTOR_STOMP_STOMPCMSTEMPLATETEST_H_
+#define _INTEGRATION_CONNECTOR_STOMP_STOMPCMSTEMPLATETEST_H_
+
+#include <activemq/test/CmsTemplateTest.h>
+#include <activemq/util/IntegrationCommon.h>
+
+namespace activemq{
+namespace test{
+namespace stomp{
+
+ class StompCmsTemplateTest : public CmsTemplateTest {
+
+ CPPUNIT_TEST_SUITE( StompCmsTemplateTest );
+ CPPUNIT_TEST( testBasics );
+ CPPUNIT_TEST( testReceiveException );
+ CPPUNIT_TEST( testSendException );
+ CPPUNIT_TEST_SUITE_END();
+
+ public:
+
+ StompCmsTemplateTest();
+ virtual ~StompCmsTemplateTest();
+
+ virtual std::string getBrokerURL() const {
+ return activemq::util::IntegrationCommon::getInstance().getStompURL();
+ }
+
+ };
+
+}}}
+
+#endif /*_INTEGRATION_CONNECTOR_STOMP_STOMPCMSTEMPLATETEST_H_*/
Propchange: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompCmsTemplateTest.h
------------------------------------------------------------------------------
svn:eol-style = native
Added: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompDurableTest.cpp
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompDurableTest.cpp?rev=723374&view=auto
==============================================================================
--- activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompDurableTest.cpp (added)
+++ activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompDurableTest.cpp Thu Dec 4 08:56:21 2008
@@ -0,0 +1,30 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#include "StompDurableTest.h"
+
+using namespace activemq;
+using namespace activemq::test;
+using namespace activemq::test::stomp;
+
+////////////////////////////////////////////////////////////////////////////////
+StompDurableTest::StompDurableTest() {
+}
+
+////////////////////////////////////////////////////////////////////////////////
+StompDurableTest::~StompDurableTest() {
+}
Propchange: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompDurableTest.cpp
------------------------------------------------------------------------------
svn:eol-style = native
Added: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompDurableTest.h
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompDurableTest.h?rev=723374&view=auto
==============================================================================
--- activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompDurableTest.h (added)
+++ activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompDurableTest.h Thu Dec 4 08:56:21 2008
@@ -0,0 +1,46 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef _ACTIVEMQ_TEST_STOMP_STOMPDURABLETESTER_H_
+#define _ACTIVEMQ_TEST_STOMP_STOMPDURABLETESTER_H_
+
+#include <activemq/test/DurableTest.h>
+
+namespace activemq{
+namespace test{
+namespace stomp{
+
+ class StompDurableTest : public DurableTest {
+
+ CPPUNIT_TEST_SUITE( StompDurableTest );
+ CPPUNIT_TEST( testDurableConsumer );
+ CPPUNIT_TEST_SUITE_END();
+
+ public:
+
+ StompDurableTest();
+ virtual ~StompDurableTest();
+
+ virtual std::string getBrokerURL() const {
+ return activemq::util::IntegrationCommon::getInstance().getStompURL();
+ }
+
+ };
+
+}}}
+
+#endif /*_ACTIVEMQ_TEST_STOMP_STOMPDURABLETESTER_H_*/
Propchange: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompDurableTest.h
------------------------------------------------------------------------------
svn:eol-style = native
Added: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompExpirationTest.cpp
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompExpirationTest.cpp?rev=723374&view=auto
==============================================================================
--- activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompExpirationTest.cpp (added)
+++ activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompExpirationTest.cpp Thu Dec 4 08:56:21 2008
@@ -0,0 +1,32 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#include "StompExpirationTest.h"
+
+using namespace std;
+using namespace cms;
+using namespace activemq;
+using namespace activemq::test;
+using namespace activemq::test::stomp;
+
+////////////////////////////////////////////////////////////////////////////////
+StompExpirationTest::StompExpirationTest() {
+}
+
+////////////////////////////////////////////////////////////////////////////////
+StompExpirationTest::~StompExpirationTest() {
+}
Propchange: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompExpirationTest.cpp
------------------------------------------------------------------------------
svn:eol-style = native
Added: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompExpirationTest.h
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompExpirationTest.h?rev=723374&view=auto
==============================================================================
--- activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompExpirationTest.h (added)
+++ activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompExpirationTest.h Thu Dec 4 08:56:21 2008
@@ -0,0 +1,47 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef _ACTIVEMQ_TEST_STOMP_STOMPEXPIRATIONTEST_H_
+#define _ACTIVEMQ_TEST_STOMP_STOMPEXPIRATIONTEST_H_
+
+#include <activemq/test/ExpirationTest.h>
+
+namespace activemq{
+namespace test{
+namespace stomp{
+
+ class StompExpirationTest : public ExpirationTest {
+
+ CPPUNIT_TEST_SUITE( StompExpirationTest );
+ CPPUNIT_TEST( testExpired );
+ CPPUNIT_TEST( testNotExpired );
+ CPPUNIT_TEST_SUITE_END();
+
+ public:
+
+ StompExpirationTest();
+ virtual ~StompExpirationTest();
+
+ virtual std::string getBrokerURL() const {
+ return activemq::util::IntegrationCommon::getInstance().getStompURL();
+ }
+
+ };
+
+}}}
+
+#endif /*_ACTIVEMQ_TEST_STOMP_STOMPEXPIRATIONTEST_H_*/
Propchange: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompExpirationTest.h
------------------------------------------------------------------------------
svn:eol-style = native
Added: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompSimpleRollbackTest.cpp
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompSimpleRollbackTest.cpp?rev=723374&view=auto
==============================================================================
--- activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompSimpleRollbackTest.cpp (added)
+++ activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompSimpleRollbackTest.cpp Thu Dec 4 08:56:21 2008
@@ -0,0 +1,32 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#include "StompSimpleRollbackTest.h"
+
+using namespace std;
+using namespace cms;
+using namespace activemq;
+using namespace activemq::test;
+using namespace activemq::test::stomp;
+
+////////////////////////////////////////////////////////////////////////////////
+StompSimpleRollbackTest::StompSimpleRollbackTest() {
+}
+
+////////////////////////////////////////////////////////////////////////////////
+StompSimpleRollbackTest::~StompSimpleRollbackTest() {
+}
Propchange: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompSimpleRollbackTest.cpp
------------------------------------------------------------------------------
svn:eol-style = native
Added: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompSimpleRollbackTest.h
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompSimpleRollbackTest.h?rev=723374&view=auto
==============================================================================
--- activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompSimpleRollbackTest.h (added)
+++ activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompSimpleRollbackTest.h Thu Dec 4 08:56:21 2008
@@ -0,0 +1,46 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef _ACTIVEMQ_TEST_STOMP_STOMPSIMPLEROLLBACKTEST_H_
+#define _ACTIVEMQ_TEST_STOMP_STOMPSIMPLEROLLBACKTEST_H_
+
+#include <activemq/test/SimpleRollbackTest.h>
+
+namespace activemq{
+namespace test{
+namespace stomp{
+
+ class StompSimpleRollbackTest : public SimpleRollbackTest {
+
+ CPPUNIT_TEST_SUITE( StompSimpleRollbackTest );
+ CPPUNIT_TEST( testRollbacks );
+ CPPUNIT_TEST_SUITE_END();
+
+ public:
+
+ StompSimpleRollbackTest();
+ virtual ~StompSimpleRollbackTest();
+
+ virtual std::string getBrokerURL() const {
+ return activemq::util::IntegrationCommon::getInstance().getStompURL();
+ }
+
+ };
+
+}}}
+
+#endif /*_ACTIVEMQ_TEST_STOMP_STOMPSIMPLEROLLBACKTEST_H_*/
Propchange: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompSimpleRollbackTest.h
------------------------------------------------------------------------------
svn:eol-style = native
Added: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompSimpleTest.cpp
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompSimpleTest.cpp?rev=723374&view=auto
==============================================================================
--- activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompSimpleTest.cpp (added)
+++ activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompSimpleTest.cpp Thu Dec 4 08:56:21 2008
@@ -0,0 +1,32 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#include "StompSimpleTest.h"
+
+using namespace std;
+using namespace cms;
+using namespace activemq;
+using namespace activemq::test;
+using namespace activemq::test::stomp;
+
+////////////////////////////////////////////////////////////////////////////////
+StompSimpleTest::StompSimpleTest() {
+}
+
+////////////////////////////////////////////////////////////////////////////////
+StompSimpleTest::~StompSimpleTest() {
+}
Propchange: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompSimpleTest.cpp
------------------------------------------------------------------------------
svn:eol-style = native
Added: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompSimpleTest.h
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompSimpleTest.h?rev=723374&view=auto
==============================================================================
--- activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompSimpleTest.h (added)
+++ activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompSimpleTest.h Thu Dec 4 08:56:21 2008
@@ -0,0 +1,54 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef _ACTIVEMQ_TEST_STOMP_STOMPSIMPLETESTER_H_
+#define _ACTIVEMQ_TEST_STOMP_STOMPSIMPLETESTER_H_
+
+#include <activemq/test/SimpleTest.h>
+
+namespace activemq{
+namespace test{
+namespace stomp{
+
+ class StompSimpleTest : public SimpleTest {
+
+ CPPUNIT_TEST_SUITE( StompSimpleTest );
+ CPPUNIT_TEST( testAutoAck );
+ CPPUNIT_TEST( testClientAck );
+ CPPUNIT_TEST( testProducerWithNullDestination );
+ CPPUNIT_TEST( testSyncReceive );
+ CPPUNIT_TEST( testSyncReceiveClientAck );
+ CPPUNIT_TEST( testMultipleConnections );
+ CPPUNIT_TEST( testMultipleSessions );
+ CPPUNIT_TEST( testReceiveAlreadyInQueue );
+ CPPUNIT_TEST( testQuickCreateAndDestroy );
+ CPPUNIT_TEST_SUITE_END();
+
+ public:
+
+ StompSimpleTest();
+ virtual ~StompSimpleTest();
+
+ virtual std::string getBrokerURL() const {
+ return activemq::util::IntegrationCommon::getInstance().getStompURL();
+ }
+
+ };
+
+}}}
+
+#endif /*_ACTIVEMQ_TEST_STOMP_STOMPSIMPLETESTER_H_*/
Propchange: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompSimpleTest.h
------------------------------------------------------------------------------
svn:eol-style = native
Added: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompSlowListenerTest.cpp
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompSlowListenerTest.cpp?rev=723374&view=auto
==============================================================================
--- activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompSlowListenerTest.cpp (added)
+++ activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompSlowListenerTest.cpp Thu Dec 4 08:56:21 2008
@@ -0,0 +1,33 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#include "StompSlowListenerTest.h"
+
+using namespace std;
+using namespace cms;
+using namespace activemq;
+using namespace activemq::test;
+using namespace activemq::test::stomp;
+using namespace activemq::util;
+
+////////////////////////////////////////////////////////////////////////////////
+StompSlowListenerTest::StompSlowListenerTest() {
+}
+
+////////////////////////////////////////////////////////////////////////////////
+StompSlowListenerTest::~StompSlowListenerTest() {
+}
Propchange: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompSlowListenerTest.cpp
------------------------------------------------------------------------------
svn:eol-style = native
Added: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompSlowListenerTest.h
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompSlowListenerTest.h?rev=723374&view=auto
==============================================================================
--- activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompSlowListenerTest.h (added)
+++ activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompSlowListenerTest.h Thu Dec 4 08:56:21 2008
@@ -0,0 +1,46 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef _ACTIVEMQ_TEST_STOMP_STOMPSLOWLISTENERTEST_H_
+#define _ACTIVEMQ_TEST_STOMP_STOMPSLOWLISTENERTEST_H_
+
+#include <activemq/test/SlowListenerTest.h>
+
+namespace activemq{
+namespace test{
+namespace stomp{
+
+ class StompSlowListenerTest : public SlowListenerTest {
+
+ CPPUNIT_TEST_SUITE( StompSlowListenerTest );
+ CPPUNIT_TEST( testSlowListener );
+ CPPUNIT_TEST_SUITE_END();
+
+ public:
+
+ StompSlowListenerTest();
+ virtual ~StompSlowListenerTest();
+
+ virtual std::string getBrokerURL() const {
+ return activemq::util::IntegrationCommon::getInstance().getStompURL();
+ }
+
+ };
+
+}}}
+
+#endif /*_ACTIVEMQ_TEST_STOMP_STOMPSLOWLISTENERTEST_H_*/
Propchange: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompSlowListenerTest.h
------------------------------------------------------------------------------
svn:eol-style = native
Added: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompTransactionTest.cpp
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompTransactionTest.cpp?rev=723374&view=auto
==============================================================================
--- activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompTransactionTest.cpp (added)
+++ activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompTransactionTest.cpp Thu Dec 4 08:56:21 2008
@@ -0,0 +1,32 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#include "StompTransactionTest.h"
+
+using namespace std;
+using namespace cms;
+using namespace activemq;
+using namespace activemq::test;
+using namespace activemq::test::stomp;
+
+////////////////////////////////////////////////////////////////////////////////
+StompTransactionTest::StompTransactionTest() {
+}
+
+////////////////////////////////////////////////////////////////////////////////
+StompTransactionTest::~StompTransactionTest() {
+}
Propchange: activemq/activemq-cpp/trunk/src/test-integration/activemq/test/stomp/StompTransactionTest.cpp
------------------------------------------------------------------------------
svn:eol-style = native