From 527f5a81233eecbe0a23aaf97286cd8da042a135 Mon Sep 17 00:00:00 2001 From: Tomohisa Igarashi Date: Fri, 7 Aug 2015 14:44:40 +0900 Subject: [PATCH] SWITCHYARD-2774 Add deployment test for camel-atom and camel-rss qs Also removed unused imports from existing tests --- .../quickstarts/BPMServiceQuickstartTest.java | 1 - .../BeanServiceQuickstartTest.java | 3 +- .../CamelAtomBindingQuickstartTest.java | 37 +++++++++++++++++++ .../CamelJMSBindingQuickstartTest.java | 3 +- .../CamelRSSBindingQuickstartTest.java | 37 +++++++++++++++++++ .../quickstarts/CamelSaxonQuickstartTest.java | 3 +- .../CamelServiceQuickstartTest.java | 3 -- .../quickstarts/EarDeployQuickstartTest.java | 3 +- .../HttpBindingQuickstartTest.java | 1 - .../JCAInflowHornetQQuickstartTest.java | 3 +- .../SoapAttachmentQuickstartTest.java | 9 ----- .../quickstarts/SoapMtomQuickstartTest.java | 1 - .../ValidateXmlQuickstartTest.java | 1 - 13 files changed, 79 insertions(+), 26 deletions(-) create mode 100644 release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/CamelAtomBindingQuickstartTest.java create mode 100644 release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/CamelRSSBindingQuickstartTest.java diff --git a/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/BPMServiceQuickstartTest.java b/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/BPMServiceQuickstartTest.java index ce28ee8eb..b878da7cd 100644 --- a/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/BPMServiceQuickstartTest.java +++ b/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/BPMServiceQuickstartTest.java @@ -17,7 +17,6 @@ import org.jboss.arquillian.container.test.api.Deployment; import org.jboss.arquillian.junit.Arquillian; import org.jboss.shrinkwrap.api.spec.JavaArchive; -import org.junit.Assert; import org.junit.Test; import org.junit.runner.RunWith; import org.switchyard.test.ArquillianUtil; diff --git a/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/BeanServiceQuickstartTest.java b/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/BeanServiceQuickstartTest.java index adb3a55ca..f9387f4b6 100644 --- a/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/BeanServiceQuickstartTest.java +++ b/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/BeanServiceQuickstartTest.java @@ -18,8 +18,6 @@ import javax.xml.namespace.QName; -import junit.framework.Assert; - import org.custommonkey.xmlunit.XMLAssert; import org.custommonkey.xmlunit.XMLUnit; import org.jboss.arquillian.container.test.api.Deployment; @@ -29,6 +27,7 @@ import org.jboss.as.controller.descriptions.ModelDescriptionConstants; import org.jboss.dmr.ModelNode; import org.jboss.shrinkwrap.api.spec.JavaArchive; +import org.junit.Assert; import org.junit.Test; import org.junit.runner.RunWith; import org.switchyard.common.type.Classes; diff --git a/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/CamelAtomBindingQuickstartTest.java b/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/CamelAtomBindingQuickstartTest.java new file mode 100644 index 000000000..e78b3581d --- /dev/null +++ b/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/CamelAtomBindingQuickstartTest.java @@ -0,0 +1,37 @@ +/* + * Copyright 2013 Red Hat Inc. and/or its affiliates and other contributors. + * + * Licensed 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. + */ +package org.switchyard.test.quickstarts; + +import org.jboss.arquillian.container.test.api.Deployment; +import org.jboss.arquillian.junit.Arquillian; +import org.jboss.shrinkwrap.api.spec.JavaArchive; +import org.junit.Assert; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.switchyard.test.ArquillianUtil; + +@RunWith(Arquillian.class) +public class CamelAtomBindingQuickstartTest { + + @Deployment(testable = false) + public static JavaArchive createDeployment() { + return ArquillianUtil.createJarQSDeployment("switchyard-camel-atom-binding"); + } + + @Test + public void testDeployment() throws Exception { + Assert.assertNotNull("Dummy not null", ""); + } + +} diff --git a/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/CamelJMSBindingQuickstartTest.java b/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/CamelJMSBindingQuickstartTest.java index 03bab39ef..ab0cd3233 100644 --- a/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/CamelJMSBindingQuickstartTest.java +++ b/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/CamelJMSBindingQuickstartTest.java @@ -22,8 +22,6 @@ import javax.jms.Session; import javax.xml.namespace.QName; -import junit.framework.Assert; - import org.jboss.arquillian.container.test.api.Deployment; import org.jboss.arquillian.junit.Arquillian; import org.jboss.arquillian.test.api.ArquillianResource; @@ -31,6 +29,7 @@ import org.jboss.as.controller.descriptions.ModelDescriptionConstants; import org.jboss.dmr.ModelNode; import org.jboss.shrinkwrap.api.spec.JavaArchive; +import org.junit.Assert; import org.junit.Test; import org.junit.runner.RunWith; import org.switchyard.component.test.mixins.hornetq.HornetQMixIn; diff --git a/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/CamelRSSBindingQuickstartTest.java b/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/CamelRSSBindingQuickstartTest.java new file mode 100644 index 000000000..96856f141 --- /dev/null +++ b/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/CamelRSSBindingQuickstartTest.java @@ -0,0 +1,37 @@ +/* + * Copyright 2013 Red Hat Inc. and/or its affiliates and other contributors. + * + * Licensed 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. + */ +package org.switchyard.test.quickstarts; + +import org.jboss.arquillian.container.test.api.Deployment; +import org.jboss.arquillian.junit.Arquillian; +import org.jboss.shrinkwrap.api.spec.JavaArchive; +import org.junit.Assert; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.switchyard.test.ArquillianUtil; + +@RunWith(Arquillian.class) +public class CamelRSSBindingQuickstartTest { + + @Deployment(testable = false) + public static JavaArchive createDeployment() { + return ArquillianUtil.createJarQSDeployment("switchyard-camel-rss-binding"); + } + + @Test + public void testDeployment() throws Exception { + Assert.assertNotNull("Dummy not null", ""); + } + +} diff --git a/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/CamelSaxonQuickstartTest.java b/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/CamelSaxonQuickstartTest.java index 52c805e20..0e2a5795c 100644 --- a/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/CamelSaxonQuickstartTest.java +++ b/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/CamelSaxonQuickstartTest.java @@ -15,8 +15,6 @@ import javax.xml.namespace.QName; -import junit.framework.Assert; - import org.jboss.arquillian.container.test.api.Deployment; import org.jboss.arquillian.junit.Arquillian; import org.jboss.arquillian.test.api.ArquillianResource; @@ -24,6 +22,7 @@ import org.jboss.as.controller.descriptions.ModelDescriptionConstants; import org.jboss.dmr.ModelNode; import org.jboss.shrinkwrap.api.spec.JavaArchive; +import org.junit.Assert; import org.junit.Test; import org.junit.runner.RunWith; import org.switchyard.component.test.mixins.http.HTTPMixIn; diff --git a/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/CamelServiceQuickstartTest.java b/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/CamelServiceQuickstartTest.java index be46f8a92..e7fb29ef8 100644 --- a/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/CamelServiceQuickstartTest.java +++ b/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/CamelServiceQuickstartTest.java @@ -13,14 +13,11 @@ */ package org.switchyard.test.quickstarts; -import java.io.IOException; - import javax.xml.namespace.QName; import org.jboss.arquillian.container.test.api.Deployment; import org.jboss.arquillian.junit.Arquillian; import org.jboss.shrinkwrap.api.spec.JavaArchive; -import org.junit.Assert; import org.junit.Test; import org.junit.runner.RunWith; import org.switchyard.remote.RemoteInvoker; diff --git a/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/EarDeployQuickstartTest.java b/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/EarDeployQuickstartTest.java index a63d86f18..b0de4fd59 100644 --- a/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/EarDeployQuickstartTest.java +++ b/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/EarDeployQuickstartTest.java @@ -21,11 +21,10 @@ import javax.jms.Session; import javax.jms.TextMessage; -import junit.framework.Assert; - import org.jboss.arquillian.container.test.api.Deployment; import org.jboss.arquillian.junit.Arquillian; import org.jboss.shrinkwrap.api.spec.EnterpriseArchive; +import org.junit.Assert; import org.junit.Test; import org.junit.runner.RunWith; import org.switchyard.component.test.mixins.hornetq.HornetQMixIn; diff --git a/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/HttpBindingQuickstartTest.java b/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/HttpBindingQuickstartTest.java index b69344b90..5275e97d1 100644 --- a/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/HttpBindingQuickstartTest.java +++ b/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/HttpBindingQuickstartTest.java @@ -26,7 +26,6 @@ import org.junit.Test; import org.junit.runner.RunWith; import org.switchyard.test.ArquillianUtil; -import org.switchyard.test.SwitchYardTestKit; import org.switchyard.component.test.mixins.http.HTTPMixIn; @RunWith(Arquillian.class) diff --git a/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/JCAInflowHornetQQuickstartTest.java b/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/JCAInflowHornetQQuickstartTest.java index 6825f085e..544d252dc 100644 --- a/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/JCAInflowHornetQQuickstartTest.java +++ b/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/JCAInflowHornetQQuickstartTest.java @@ -23,8 +23,6 @@ import javax.jms.TextMessage; import javax.xml.namespace.QName; -import junit.framework.Assert; - import org.jboss.arquillian.container.test.api.Deployment; import org.jboss.arquillian.junit.Arquillian; import org.jboss.arquillian.test.api.ArquillianResource; @@ -32,6 +30,7 @@ import org.jboss.as.controller.descriptions.ModelDescriptionConstants; import org.jboss.dmr.ModelNode; import org.jboss.shrinkwrap.api.spec.JavaArchive; +import org.junit.Assert; import org.junit.Test; import org.junit.runner.RunWith; import org.switchyard.test.ArquillianUtil; diff --git a/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/SoapAttachmentQuickstartTest.java b/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/SoapAttachmentQuickstartTest.java index ab68ad520..210b6d172 100644 --- a/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/SoapAttachmentQuickstartTest.java +++ b/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/SoapAttachmentQuickstartTest.java @@ -13,18 +13,13 @@ */ package org.switchyard.test.quickstarts; -import java.io.File; import java.io.InputStream; import java.io.IOException; import java.io.OutputStream; -import java.net.MalformedURLException; import java.net.URL; -import java.util.Map; -import java.util.Iterator; import javax.activation.DataHandler; import javax.activation.DataSource; -import javax.jws.WebService; import javax.xml.namespace.QName; import javax.xml.soap.AttachmentPart; import javax.xml.soap.MessageFactory; @@ -32,18 +27,14 @@ import javax.xml.soap.SOAPConnection; import javax.xml.soap.SOAPConnectionFactory; import javax.xml.soap.SOAPConstants; -import javax.xml.soap.SOAPElement; import javax.xml.soap.SOAPMessage; -import org.custommonkey.xmlunit.XMLAssert; -import org.custommonkey.xmlunit.XMLUnit; import org.jboss.arquillian.container.test.api.Deployment; import org.jboss.arquillian.junit.Arquillian; import org.jboss.shrinkwrap.api.spec.JavaArchive; import org.junit.Assert; import org.junit.Test; import org.junit.runner.RunWith; -import org.switchyard.component.test.mixins.http.HTTPMixIn; import org.switchyard.test.ArquillianUtil; /* diff --git a/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/SoapMtomQuickstartTest.java b/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/SoapMtomQuickstartTest.java index 199fb1ec3..d268e03c5 100644 --- a/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/SoapMtomQuickstartTest.java +++ b/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/SoapMtomQuickstartTest.java @@ -32,7 +32,6 @@ import org.junit.Test; import org.junit.runner.RunWith; import org.switchyard.common.xml.XMLHelper; -import org.switchyard.component.soap.util.SOAPUtil; import org.switchyard.test.ArquillianUtil; /* diff --git a/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/ValidateXmlQuickstartTest.java b/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/ValidateXmlQuickstartTest.java index 8afdb1816..d1ed581d7 100644 --- a/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/ValidateXmlQuickstartTest.java +++ b/release/jboss-as7/tests/src/test/java/org/switchyard/test/quickstarts/ValidateXmlQuickstartTest.java @@ -13,7 +13,6 @@ */ package org.switchyard.test.quickstarts; -import org.custommonkey.xmlunit.XMLAssert; import org.jboss.arquillian.container.test.api.Deployment; import org.jboss.arquillian.junit.Arquillian; import org.jboss.shrinkwrap.api.spec.JavaArchive;