use of org.eclipse.tycho.p2.target.facade.TargetDefinition in project tycho by eclipse.
the class TargetDefinitionResolverTest method testResolveMultipleUnits.
@Test
public void testResolveMultipleUnits() throws Exception {
TargetDefinition definition = definitionWith(new LocationStub(OPTIONAL_BUNDLE, REFERENCED_BUNDLE_V1));
TargetDefinitionContent units = subject.resolveContent(definition);
assertThat(versionedIdsOf(units), bagEquals(versionedIdList(REFERENCED_BUNDLE_V1, OPTIONAL_BUNDLE)));
}
use of org.eclipse.tycho.p2.target.facade.TargetDefinition in project tycho by eclipse.
the class TargetDefinitionResolverTest method testUnitOnlyLookedUpInLocation.
@Test(expected = TargetDefinitionResolutionException.class)
public void testUnitOnlyLookedUpInLocation() throws Exception {
TargetDefinition definition = definitionWith(new LocationStub(TestRepositories.V2, MAIN_BUNDLE), new LocationStub(TestRepositories.V1));
subject.resolveContentWithExceptions(definition);
}
use of org.eclipse.tycho.p2.target.facade.TargetDefinition in project tycho by eclipse.
the class TargetDefinitionResolverTest method testUnitWithWildcardVersion.
@Test
public void testUnitWithWildcardVersion() {
TargetDefinition definition = definitionWith(new LocationStub(TestRepositories.V1_AND_V2, REFERENCED_BUNDLE_WILDCARD_VERSION));
TargetDefinitionContent units = subject.resolveContent(definition);
assertThat(versionedIdsOf(units), bagEquals(versionedIdList(REFERENCED_BUNDLE_V2)));
}
use of org.eclipse.tycho.p2.target.facade.TargetDefinition in project tycho by eclipse.
the class TargetDefinitionResolverTest method testResolveIncludesDependencies.
@Test
public void testResolveIncludesDependencies() throws Exception {
TargetDefinition definition = definitionWith(new LocationStub(TestRepositories.V1_AND_V2, TARGET_FEATURE));
TargetDefinitionContent units = subject.resolveContent(definition);
assertThat(versionedIdsOf(units), hasItem(MAIN_BUNDLE));
assertThat(versionedIdsOf(units), hasItem(REFERENCED_BUNDLE_V1));
}
use of org.eclipse.tycho.p2.target.facade.TargetDefinition in project tycho by eclipse.
the class TargetDefinitionResolverTest method testInvalidRepository.
@Test(expected = TargetDefinitionResolutionException.class)
public void testInvalidRepository() throws Exception {
TargetDefinition definition = definitionWith(new LocationStub(TestRepositories.INVALID, TARGET_FEATURE));
subject.resolveContentWithExceptions(definition);
}
Aggregations