Search in sources :

Example 1 with MavenContextImpl

use of org.eclipse.tycho.core.shared.MavenContextImpl in project tycho by eclipse.

the class PomDependencyCollectorTest method setUpSubject.

@Before
public void setUpSubject() throws Exception {
    MavenContextImpl mavenContext = new MavenContextImpl(new File("dummy"), logVerifier.getLogger());
    subject = new PomDependencyCollectorImpl(mavenContext);
}
Also used : MavenContextImpl(org.eclipse.tycho.core.shared.MavenContextImpl) File(java.io.File) Before(org.junit.Before)

Example 2 with MavenContextImpl

use of org.eclipse.tycho.core.shared.MavenContextImpl in project tycho by eclipse.

the class VerifierServiceImplTest method setup.

@Before
public void setup() {
    subject = new VerifierServiceImpl();
    logger = new ErrorStoreMemoryLog();
    MavenContext mavenContext = new MavenContextImpl(null, logger);
    subject.setMavenContext(mavenContext);
}
Also used : MavenContextImpl(org.eclipse.tycho.core.shared.MavenContextImpl) MavenContext(org.eclipse.tycho.core.shared.MavenContext) VerifierServiceImpl(org.eclipse.tycho.p2.tools.verifier.VerifierServiceImpl) Before(org.junit.Before)

Example 3 with MavenContextImpl

use of org.eclipse.tycho.core.shared.MavenContextImpl in project tycho by eclipse.

the class RemoteAgentCompositeLoadingTest method initSubject.

@Before
public void initSubject() throws Exception {
    File localRepo = tempManager.newFolder("localRepo");
    subject = new RemoteAgent(new MavenContextImpl(localRepo, logVerifier.getLogger()));
}
Also used : MavenContextImpl(org.eclipse.tycho.core.shared.MavenContextImpl) File(java.io.File) Before(org.junit.Before)

Example 4 with MavenContextImpl

use of org.eclipse.tycho.core.shared.MavenContextImpl in project tycho by eclipse.

the class RemoteAgentMavenMirrorsTest method initSubject.

@Before
public void initSubject() throws Exception {
    File localRepository = tempManager.newFolder("localRepo");
    MavenContext mavenContext = new MavenContextImpl(localRepository, OFFLINE, logVerifier.getLogger(), new Properties());
    mavenRepositorySettings = new MavenRepositorySettingsStub();
    subject = new RemoteAgent(mavenContext, mavenRepositorySettings, OFFLINE);
}
Also used : MavenContextImpl(org.eclipse.tycho.core.shared.MavenContextImpl) MavenContext(org.eclipse.tycho.core.shared.MavenContext) MavenRepositorySettingsStub(org.eclipse.tycho.p2.remote.testutil.MavenRepositorySettingsStub) Properties(java.util.Properties) File(java.io.File) Before(org.junit.Before)

Example 5 with MavenContextImpl

use of org.eclipse.tycho.core.shared.MavenContextImpl in project tycho by eclipse.

the class MavenContextConfigurator method afterFrameworkStarted.

@Override
public void afterFrameworkStarted(EmbeddedEquinox framework) {
    MavenSession session = context.getSession();
    File localRepoRoot = new File(session.getLocalRepository().getBasedir());
    MavenLoggerAdapter mavenLogger = new MavenLoggerAdapter(logger, false);
    Properties globalProps = getGlobalProperties(session);
    MavenContext mavenContext = new MavenContextImpl(localRepoRoot, session.isOffline(), mavenLogger, globalProps);
    framework.registerService(MavenContext.class, mavenContext);
}
Also used : MavenSession(org.apache.maven.execution.MavenSession) MavenContextImpl(org.eclipse.tycho.core.shared.MavenContextImpl) MavenLoggerAdapter(org.eclipse.tycho.osgi.adapters.MavenLoggerAdapter) MavenContext(org.eclipse.tycho.core.shared.MavenContext) Properties(java.util.Properties) File(java.io.File)

Aggregations

MavenContextImpl (org.eclipse.tycho.core.shared.MavenContextImpl)7 Before (org.junit.Before)6 File (java.io.File)5 MavenContext (org.eclipse.tycho.core.shared.MavenContext)5 Properties (java.util.Properties)2 DestinationRepositoryDescriptor (org.eclipse.tycho.p2.tools.DestinationRepositoryDescriptor)2 MavenSession (org.apache.maven.execution.MavenSession)1 BuildOutputDirectory (org.eclipse.tycho.BuildOutputDirectory)1 ReactorProjectIdentities (org.eclipse.tycho.ReactorProjectIdentities)1 MavenLoggerAdapter (org.eclipse.tycho.osgi.adapters.MavenLoggerAdapter)1 MavenRepositorySettingsStub (org.eclipse.tycho.p2.remote.testutil.MavenRepositorySettingsStub)1 BuildContext (org.eclipse.tycho.p2.tools.BuildContext)1 VerifierServiceImpl (org.eclipse.tycho.p2.tools.verifier.VerifierServiceImpl)1 ReactorProjectIdentitiesStub (org.eclipse.tycho.test.util.ReactorProjectIdentitiesStub)1