X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?p=controller.git;a=blobdiff_plain;f=opendaylight%2Fmd-sal%2Fmdsal-it-base%2Fsrc%2Fmain%2Fjava%2Forg%2Fopendaylight%2Fcontroller%2Fmdsal%2Fit%2Fbase%2FAbstractMdsalTestBase.java;h=cf74e7dc8b579de68be0cf3b48c1a7b3b8f0fbb9;hp=ad0934122dd565f200344760110b88ea4676d30c;hb=d429d95060d4741f37c4d5a09e7de386e77cd925;hpb=3b9a2d4870110d14d7e2b6ea672023fd18328c8b diff --git a/opendaylight/md-sal/mdsal-it-base/src/main/java/org/opendaylight/controller/mdsal/it/base/AbstractMdsalTestBase.java b/opendaylight/md-sal/mdsal-it-base/src/main/java/org/opendaylight/controller/mdsal/it/base/AbstractMdsalTestBase.java index ad0934122d..cf74e7dc8b 100644 --- a/opendaylight/md-sal/mdsal-it-base/src/main/java/org/opendaylight/controller/mdsal/it/base/AbstractMdsalTestBase.java +++ b/opendaylight/md-sal/mdsal-it-base/src/main/java/org/opendaylight/controller/mdsal/it/base/AbstractMdsalTestBase.java @@ -38,7 +38,6 @@ public abstract class AbstractMdsalTestBase { private static final Logger LOG = LoggerFactory.getLogger(AbstractMdsalTestBase.class); private static final String MAVEN_REPO_LOCAL = "maven.repo.local"; - private static final String ORG_OPS4J_PAX_URL_MVN_LOCAL_REPOSITORY = "org.ops4j.pax.url.mvn.localRepository"; private static final String ETC_ORG_OPS4J_PAX_URL_MVN_CFG = "etc/org.ops4j.pax.url.mvn.cfg"; private static final String ETC_ORG_OPS4J_PAX_LOGGING_CFG = "etc/org.ops4j.pax.logging.cfg"; @@ -91,7 +90,7 @@ public abstract class AbstractMdsalTestBase { * @return An array of additional config options */ protected Option[] getAdditionalOptions() { - return null; + return new Option[0]; } /** @@ -117,8 +116,8 @@ public abstract class AbstractMdsalTestBase { protected Option mvnLocalRepoOption() { String mvnRepoLocal = System.getProperty(MAVEN_REPO_LOCAL, ""); LOG.info("mvnLocalRepo \"{}\"", mvnRepoLocal); - return editConfigurationFilePut(ETC_ORG_OPS4J_PAX_URL_MVN_CFG, ORG_OPS4J_PAX_URL_MVN_LOCAL_REPOSITORY, - mvnRepoLocal); + return editConfigurationFilePut(ETC_ORG_OPS4J_PAX_URL_MVN_CFG, + "org.ops4j.pax.url.mvn.localRepository", mvnRepoLocal); } @Configuration @@ -130,8 +129,12 @@ public abstract class AbstractMdsalTestBase { .unpackDirectory(new File(PAX_EXAM_UNPACK_DIRECTORY)).useDeployFolder(false), when(Boolean.getBoolean(KEEP_UNPACK_DIRECTORY_PROP)).useOptions(keepRuntimeFolder()), features(getFeatureRepo(), getFeatureName()), - //mavenBundle("org.apache.aries.quiesce", "org.apache.aries.quiesce.api", "1.0.0"), getLoggingOption(), mvnLocalRepoOption(), + + // Make sure karaf's default repository is consulted before anything else + editConfigurationFilePut(ETC_ORG_OPS4J_PAX_URL_MVN_CFG, "org.ops4j.pax.url.mvn.defaultRepositories", + "file:${karaf.home}/${karaf.default.repository}@id=system.repository"), + configureConsole().ignoreLocalConsole().ignoreRemoteShell(), editConfigurationFilePut(ETC_ORG_OPS4J_PAX_LOGGING_CFG, "log4j2.rootLogger.level", "INFO") };