use of org.ops4j.pax.exam.Configuration in project cxf by apache.
the class BasicIntegrationTest method getConfig.
@Configuration
public Option[] getConfig() {
String port = TestUtil.getPortNumber(BasicIntegrationTest.class);
System.setProperty("BasicIntegrationTest.PORT", port);
String xkmsEndpoint = "http://localhost:" + port + "/cxf/XKMS";
String karafVersion = System.getProperty("karaf.version", "4.0.8");
String localRepository = System.getProperty("localRepository");
MavenArtifactUrlReference karafUrl = //
maven().groupId(//
"org.apache.karaf").artifactId(//
"apache-karaf").version(karafVersion).type("tar.gz");
MavenArtifactUrlReference xkmsFeatures = //
maven().groupId(//
"org.apache.cxf.services.xkms").artifactId(//
"cxf-services-xkms-features").versionAsInProject().type("xml");
return new Option[] { karafDistributionConfiguration().frameworkUrl(karafUrl).karafVersion(karafVersion).unpackDirectory(new File("target/paxexam/unpack/")).useDeployFolder(false), systemProperty("java.awt.headless").value("true"), systemProperty("BasicIntegrationTest.PORT").value(port), copy("data/xkms/certificates/trusted_cas/root.cer"), copy("data/xkms/certificates/trusted_cas/wss40CA.cer"), copy("data/xkms/certificates/cas/alice.cer"), copy("data/xkms/certificates/dave.cer"), copy("data/xkms/certificates/http___localhost_8080_services_TestService.cer"), copy("etc/org.ops4j.pax.logging.cfg"), // 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", port), editConfigurationFilePut("etc/org.apache.cxf.xkms.client.cfg", "xkms.endpoint", xkmsEndpoint), when(localRepository != null).useOptions(editConfigurationFilePut("etc/org.ops4j.pax.url.mvn.cfg", "org.ops4j.pax.url.mvn.localRepository", localRepository)), features(xkmsFeatures, "cxf-xkms-service", "cxf-xkms-client", "cxf-xkms-ldap"), configureConsole().ignoreLocalConsole() // org.ops4j.pax.exam.karaf.options.KarafDistributionOption.keepRuntimeFolder(),
// CoreOptions.vmOption("-Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=5005")
};
}
Aggregations