Skip to content
Permalink
Browse files
Make an attempt to get the osgi based tests to pass in Jenkins
git-svn-id: https://svn.apache.org/repos/asf/cxf/trunk@1561932 13f79535-47bb-0310-9956-ffa450edef68
  • Loading branch information
dkulp committed Jan 28, 2014
1 parent 61c94e8 commit fe03e8e76db39520876a5b2e45b8d1096649f019
Show file tree
Hide file tree
Showing 4 changed files with 19 additions and 3 deletions.
@@ -20,6 +20,7 @@

import org.junit.Test;
import org.junit.runner.RunWith;

import org.ops4j.pax.exam.Configuration;
import org.ops4j.pax.exam.Option;
import org.ops4j.pax.exam.junit.PaxExam;
@@ -28,6 +29,7 @@

import static org.ops4j.pax.exam.CoreOptions.junitBundles;
import static org.ops4j.pax.exam.CoreOptions.mavenBundle;
import static org.ops4j.pax.exam.CoreOptions.systemProperty;

@RunWith(PaxExam.class)
@ExamReactorStrategy(PerClass.class)
@@ -47,6 +49,9 @@ public void testCXFBundles() throws Exception {
@Configuration
public Option[] config() {
return new Option[]{
systemProperty("java.awt.headless").value("true"),
systemProperty("org.ops4j.pax.url.mvn.localRepository")
.value(System.getProperty("localRepository")),
mavenBundle().groupId("org.apache.ws.xmlschema").artifactId("xmlschema-core").versionAsInProject(),
mavenBundle().groupId("org.apache.cxf").artifactId("cxf-core").versionAsInProject(),
mavenBundle().groupId("org.apache.servicemix.bundles")
@@ -21,14 +21,16 @@

import org.junit.Test;
import org.junit.runner.RunWith;

import org.ops4j.pax.exam.Configuration;
import org.ops4j.pax.exam.Option;
import org.ops4j.pax.exam.junit.PaxExam;
import org.ops4j.pax.exam.karaf.options.LogLevelOption.LogLevel;
import org.ops4j.pax.exam.spi.reactors.ExamReactorStrategy;
import org.ops4j.pax.exam.spi.reactors.PerClass;

import static org.ops4j.pax.exam.karaf.options.KarafDistributionOption.keepRuntimeFolder;
import static org.ops4j.pax.exam.CoreOptions.systemProperty;
import static org.ops4j.pax.exam.karaf.options.KarafDistributionOption.editConfigurationFilePut;
import static org.ops4j.pax.exam.karaf.options.KarafDistributionOption.logLevel;

@RunWith(PaxExam.class)
@@ -51,8 +53,12 @@ public void test() throws Exception {
@Configuration
public Option[] config() {
return new Option[]{
cxfBaseConfig(),
keepRuntimeFolder(),
cxfBaseConfig(),
systemProperty("java.awt.headless").value("true"),

editConfigurationFilePut("etc/org.ops4j.pax.url.mvn.cfg",
"org.ops4j.pax.url.mvn.localRepository",
System.getProperty("localRepository")),
logLevel(LogLevel.INFO)};
}
}
@@ -109,6 +109,7 @@
<project.version>${project.version}</project.version>
<karaf.version>${karaf.version}</karaf.version>
<buildDirectory>${project.build.directory}</buildDirectory>
<org.ops4j.pax.url.mvn.localRepository>${maven.repo.local}</org.ops4j.pax.url.mvn.localRepository>
</systemPropertyVariables>
</configuration>
</plugin>
@@ -66,6 +66,7 @@ public Option[] getConfig() {
.artifactId("cxf-services-xkms-features").version(projectVersion).type("xml");

return new Option[] {

karafDistributionConfiguration().frameworkUrl(karafUrl).karafVersion(karafVersion)
.unpackDirectory(new File("target/paxexam/unpack/")).useDeployFolder(false),
systemProperty("java.awt.headless").value("true"),
@@ -89,6 +90,9 @@ public Option[] getConfig() {
editConfigurationFilePut("etc/org.ops4j.pax.url.mvn.cfg", "org.ops4j.pax.url.mvn.repositories", REPOS),
editConfigurationFilePut("etc/org.ops4j.pax.web.cfg", "org.osgi.service.http.port", HTTP_PORT),
editConfigurationFilePut("etc/org.apache.cxf.xkms.client.cfg", "xkms.endpoint", XKMS_ENDPOINT),
editConfigurationFilePut("etc/org.ops4j.pax.url.mvn.cfg",
"org.ops4j.pax.url.mvn.localRepository",
System.getProperty("localRepository")),
features(xkmsFeatures, "cxf-xkms-service", "cxf-xkms-client"),
configureConsole().ignoreLocalConsole(),
//CoreOptions.vmOption("-Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=5005")

0 comments on commit fe03e8e

Please sign in to comment.