Repository: karaf Updated Branches: refs/heads/karaf-2.x 8c137a412 -> 09cb9e8f0
[KARAF-3428] Upgrade to Pax CDI 0.10.0-SNAPSHOT, cleanup features and add itests Project: http://git-wip-us.apache.org/repos/asf/karaf/repo Commit: http://git-wip-us.apache.org/repos/asf/karaf/commit/09cb9e8f Tree: http://git-wip-us.apache.org/repos/asf/karaf/tree/09cb9e8f Diff: http://git-wip-us.apache.org/repos/asf/karaf/diff/09cb9e8f Branch: refs/heads/karaf-2.x Commit: 09cb9e8f0f247fff1f38e6d7a3c4491cdf829bc8 Parents: 8c137a4 Author: Jean-Baptiste Onofré <[email protected]> Authored: Sat Jan 3 09:22:47 2015 +0100 Committer: Jean-Baptiste Onofré <[email protected]> Committed: Sat Jan 3 09:22:47 2015 +0100 ---------------------------------------------------------------------- .../enterprise/src/main/resources/features.xml | 10 +- .../itests/features/PaxCdiFeaturesTest.java | 113 +++++++++++++++++++ pom.xml | 4 +- 3 files changed, 116 insertions(+), 11 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/karaf/blob/09cb9e8f/assemblies/features/enterprise/src/main/resources/features.xml ---------------------------------------------------------------------- diff --git a/assemblies/features/enterprise/src/main/resources/features.xml b/assemblies/features/enterprise/src/main/resources/features.xml index 266b5ec..73ee1f8 100644 --- a/assemblies/features/enterprise/src/main/resources/features.xml +++ b/assemblies/features/enterprise/src/main/resources/features.xml @@ -274,18 +274,12 @@ </conditional> </feature> - <feature name="openwebbeans" description="Apache OpenWebBeans CDI container support" version="${openwebbeans.version}" resolver="(obr)"> - <details>Add support of Apache OpenWebBeans CDI container.</details> - <feature>http</feature> + <feature name="openwebbeans" description="Alias to pax-cdi-openwebbeans feature" version="${pax.cdi.version}" resolver="(obr)"> <feature>pax-cdi-openwebbeans</feature> - <bundle>mvn:org.apache.openwebbeans/openwebbeans-impl/${openwebbeans.version}</bundle> - <bundle>mvn:org.apache.openwebbeans/openwebbeans-osgi/${openwebbeans.version}</bundle> </feature> - <feature name="weld" description="JBoss Weld CDI container support" version="${weld.version}" resolver="(obr)"> - <details>Add support of JBoss Weld CDI container.</details> + <feature name="weld" description="Alias to pax-cdi-weld feature" version="${pax.cdi.version}" resolver="(obr)"> <feature>pax-cdi-weld</feature> - <bundle>mvn:org.jboss.weld/weld-osgi-bundle/${weld.version}</bundle> </feature> <feature name="application-without-isolation" description="Provide EBA archive support" version="${aries.application.version}"> http://git-wip-us.apache.org/repos/asf/karaf/blob/09cb9e8f/itests/src/test/java/org/apache/karaf/itests/features/PaxCdiFeaturesTest.java ---------------------------------------------------------------------- diff --git a/itests/src/test/java/org/apache/karaf/itests/features/PaxCdiFeaturesTest.java b/itests/src/test/java/org/apache/karaf/itests/features/PaxCdiFeaturesTest.java new file mode 100644 index 0000000..d36b14b --- /dev/null +++ b/itests/src/test/java/org/apache/karaf/itests/features/PaxCdiFeaturesTest.java @@ -0,0 +1,113 @@ +/* + * 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.apache.karaf.itests.features; + +import org.apache.karaf.itests.KarafTestSupport; +import org.junit.Ignore; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.ops4j.pax.exam.junit.PaxExam; +import org.ops4j.pax.exam.spi.reactors.ExamReactorStrategy; +import org.ops4j.pax.exam.spi.reactors.PerMethod; + +@RunWith(PaxExam.class) +@ExamReactorStrategy(PerMethod.class) +public class PaxCdiFeaturesTest extends KarafTestSupport { + + @Test + public void installPaxCdiFeature() throws Exception { + installAndAssertFeature("pax-cdi"); + } + + @Test + public void installPaxCdi11Feature() throws Exception { + installAndAssertFeature("pax-cdi-1.1"); + } + + @Test + public void installPaxCdi12Feature() throws Exception { + installAndAssertFeature("pax-cdi-1.2"); + } + + @Test + public void installPaxCdiWeldFeature() throws Exception { + installAndAssertFeature("pax-cdi-weld"); + } + + @Test + public void installPaxCdiWeld11Feature() throws Exception { + installAndAssertFeature("pax-cdi-1.1-weld"); + } + + @Test + public void installPaxCdiWeld12Feature() throws Exception { + installAndAssertFeature("pax-cdi-1.2-weld"); + } + + @Test + public void installPaxCdiOpenwebbeansFeature() throws Exception { + installAndAssertFeature("pax-cdi-openwebbeans"); + } + + @Test + public void installPaxCdiWebFeature() throws Exception { + installAndAssertFeature("pax-cdi-web"); + } + + @Test + public void installPaxCdi11WebFeature() throws Exception { + installAndAssertFeature("pax-cdi-1.1-web"); + } + + @Test + @Ignore("PAXCDI-146 Require Pax Web 4.x/Karaf 4") + public void installPaxCdi12WebFeature() throws Exception { + installAndAssertFeature("pax-cdi-1.2-web"); + } + + @Test + @Ignore("PAXCDI-146: Require Pax Web 4.x/Karaf 4") + public void installPaxCdiWebWeldFeature() throws Exception { + installAndAssertFeature("pax-cdi-web-weld"); + } + + @Test + @Ignore("PAXCDI-146: Require Pax Web 4.x/Karaf 4") + public void installPaxCdi11WebWeldFeature() throws Exception { + installAndAssertFeature("pax-cdi-1.1-web-weld"); + } + + @Test + @Ignore("PAXCDI-146: Require Pax Web 4.x/Karaf 4") + public void installPaxCdi12WebWeldFeature() throws Exception { + installAndAssertFeature("pax-cdi-1.2-web-weld"); + } + + @Test + @Ignore("PAXCDI-146: Require Pax Web 4.x/Karaf 4") + public void installPaxCdiWebOpenwebbeansFeature() throws Exception { + installAndAssertFeature("pax-cdi-web-openwebbeans"); + } + + @Test + public void installDeltaspikeCoreFeature() throws Exception { + installAndAssertFeature("deltaspike-core"); + } + + @Test + public void installDeltaspikeJpaFeature() throws Exception { + installAndAssertFeature("deltaspike-jpa"); + } + +} http://git-wip-us.apache.org/repos/asf/karaf/blob/09cb9e8f/pom.xml ---------------------------------------------------------------------- diff --git a/pom.xml b/pom.xml index 5b2a60f..ed8e41b 100644 --- a/pom.xml +++ b/pom.xml @@ -195,11 +195,10 @@ <log4j.version>1.2.17</log4j.version> <maven.version>3.0-alpha-2</maven.version> <mina.version>2.0.7</mina.version> - <openwebbeans.version>1.2.6</openwebbeans.version> <osgi.version>5.0.0</osgi.version> <org.json.version>20140107</org.json.version> <pax.base.version>1.5.0</pax.base.version> - <pax.cdi.version>0.8.0</pax.cdi.version> + <pax.cdi.version>0.10.0-SNAPSHOT</pax.cdi.version> <pax.exam.version>4.3.0</pax.exam.version> <pax.logging.version>1.8.1</pax.logging.version> <pax.url.version>2.3.0</pax.url.version> @@ -226,7 +225,6 @@ <xbean.version>3.18</xbean.version> <xerces.version>2.11.0</xerces.version> <javax.mail.version>1.4.5</javax.mail.version> - <weld.version>2.1.1.Final</weld.version> <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> <appendedResourcesDirectory>${basedir}/etc/appended-resources</appendedResourcesDirectory> <bnd.version.policy>[$(version;==;$(@)),$(version;+;$(@)))</bnd.version.policy>
