use of org.ops4j.pax.exam.Configuration in project jetty.project by eclipse.
the class TestJettyOSGiBootCore method config.
@Configuration
public Option[] config() {
VersionResolver resolver = MavenUtils.asInProject();
ArrayList<Option> options = new ArrayList<Option>();
options.addAll(provisionCoreJetty());
options.add(CoreOptions.junitBundles());
options.addAll(httpServiceJetty());
options.addAll(Arrays.asList(options(systemProperty("pax.exam.logging").value("none"))));
options.addAll(Arrays.asList(options(systemProperty("org.ops4j.pax.logging.DefaultServiceLog.level").value(LOG_LEVEL))));
options.addAll(Arrays.asList(options(systemProperty("org.eclipse.jetty.LEVEL").value(LOG_LEVEL))));
options.addAll(Arrays.asList(options(systemProperty("org.eclipse.jetty.annotations.LEVEL").value("DEBUG"))));
return options.toArray(new Option[options.size()]);
}
use of org.ops4j.pax.exam.Configuration in project aries by apache.
the class FragmentTest method configuration.
@Configuration
public Option[] configuration() {
InputStream hostJar = TinyBundles.bundle().set(Constants.BUNDLE_MANIFESTVERSION, "2").set(Constants.BUNDLE_SYMBOLICNAME, "org.apache.aries.test.host").build();
InputStream fragmentJar = TinyBundles.bundle().set(Constants.BUNDLE_MANIFESTVERSION, "2").set(Constants.BUNDLE_SYMBOLICNAME, "org.apache.aries.test.fragment").set(Constants.FRAGMENT_HOST, "org.apache.aries.test.host").add("OSGI-INF/blueprint/bp.xml", this.getClass().getResourceAsStream("/bp.xml")).build();
return new Option[] { baseOptions(), Helper.blueprintBundles(), streamBundle(fragmentJar).noStart(), streamBundle(hostJar), mvnBundle("org.apache.aries.blueprint", "org.apache.aries.blueprint.sample", false) };
}
use of org.ops4j.pax.exam.Configuration in project aries by apache.
the class AbstractTransactionTest method localEmbeddedH2LocalTxConfiguration.
@Configuration
public Option[] localEmbeddedH2LocalTxConfiguration() {
String localRepo = System.getProperty("maven.repo.local");
if (localRepo == null) {
localRepo = System.getProperty("org.ops4j.pax.url.mvn.localRepository");
}
Option testSpecificOptions = testSpecificOptions();
return options(junitBundles(), systemProperty("org.ops4j.pax.logging.DefaultServiceLog.level").value("INFO"), when(localRepo != null).useOptions(CoreOptions.vmOption("-Dorg.ops4j.pax.url.mvn.localRepository=" + localRepo)), localTxControlService(), localJdbcResourceProviderWithH2(), when(testSpecificOptions != null).useOptions(testSpecificOptions), mavenBundle("org.ops4j.pax.logging", "pax-logging-api").versionAsInProject(), mavenBundle("org.ops4j.pax.logging", "pax-logging-service").versionAsInProject());
}
use of org.ops4j.pax.exam.Configuration in project aries by apache.
the class IntegrationTestBase method configuration.
@Configuration
public static Option[] configuration() {
final String bundleFileName = System.getProperty(BUNDLE_JAR_SYS_PROP, BUNDLE_JAR_DEFAULT);
final File bundleFile = new File(bundleFileName);
if (!bundleFile.canRead()) {
throw new IllegalArgumentException("Cannot read from bundle file " + bundleFileName + " specified in the " + BUNDLE_JAR_SYS_PROP + " system property");
}
final Option[] options = options(systemProperty("org.ops4j.pax.logging.DefaultServiceLog.level").value("INFO"), junitBundles(), bundle(bundleFile.toURI().toString()), mavenBundle("org.ops4j.pax.tinybundles", "tinybundles", "2.0.0"), mavenBundle("org.apache.felix", "org.apache.felix.configadmin", "1.2.8"), mavenBundle("org.ops4j.pax.logging", "pax-logging-api", "1.7.2"), mavenBundle("org.ops4j.pax.logging", "pax-logging-service", "1.7.2"));
return options;
}
use of org.ops4j.pax.exam.Configuration in project aries by apache.
the class SubsystemTest method configuration.
@Configuration
public Option[] configuration() throws Exception {
new File("target").mkdirs();
init();
return new Option[] { baseOptions(), systemProperty("org.osgi.framework.bsnversion").value("multiple"), systemProperty("org.osgi.framework.storage.clean").value("onFirstInit"), // Bundles
mavenBundle("org.apache.aries", "org.apache.aries.util").versionAsInProject(), mavenBundle("org.apache.aries.application", "org.apache.aries.application.utils").versionAsInProject(), mavenBundle("org.apache.aries.application", "org.apache.aries.application.api").versionAsInProject(), when(installModeler).useOptions(modelerBundles()), when(installConfigAdmin).useOptions(mavenBundle("org.apache.felix", "org.apache.felix.configadmin").versionAsInProject()), mavenBundle("org.apache.aries.subsystem", "org.apache.aries.subsystem.api").versionAsInProject(), mavenBundle("org.apache.aries.subsystem", SUBSYSTEM_CORE_NAME).versionAsInProject(), streamBundle(createCoreFragment()).noStart(), mavenBundle("org.apache.aries.subsystem", "org.apache.aries.subsystem.itest.interfaces").versionAsInProject(), mavenBundle("org.apache.aries.testsupport", "org.apache.aries.testsupport.unit").versionAsInProject(), //mavenBundle("org.apache.felix", "org.apache.felix.resolver").versionAsInProject(),
mavenBundle("org.eclipse.equinox", "org.eclipse.equinox.coordinator").version("1.1.0.v20120522-1841"), mavenBundle("org.eclipse.equinox", "org.eclipse.equinox.event").versionAsInProject(), mavenBundle("org.eclipse.equinox", "org.eclipse.equinox.region").version("1.1.0.v20120522-1841"), mavenBundle("org.osgi", "org.osgi.enterprise").versionAsInProject(), mavenBundle("org.easymock", "easymock").versionAsInProject(), mavenBundle("org.ops4j.pax.logging", "pax-logging-api").versionAsInProject(), mavenBundle("org.ops4j.pax.logging", "pax-logging-service").versionAsInProject(), mavenBundle("org.ops4j.pax.tinybundles", "tinybundles").versionAsInProject(), mavenBundle("biz.aQute.bnd", "bndlib").versionAsInProject(), mavenBundle("org.apache.aries.subsystem", "org.apache.aries.subsystem.obr").versionAsInProject(), mavenBundle("org.apache.felix", "org.apache.felix.bundlerepository").versionAsInProject() };
}
Aggregations