use of org.jboss.galleon.universe.FeaturePackLocation in project galleon by wildfly.
the class FeaturePackLocationStringTestCase method testProducerUniverseFactoryFromString.
@Test
public void testProducerUniverseFactoryFromString() throws Exception {
final FeaturePackLocation parsedSrc = FeaturePackLocation.fromString("producer@factory");
Assert.assertNotNull(parsedSrc);
Assert.assertEquals(new UniverseSpec("factory"), parsedSrc.getUniverse());
Assert.assertEquals("producer", parsedSrc.getProducerName());
Assert.assertNull(parsedSrc.getChannelName());
Assert.assertNull(parsedSrc.getFrequency());
Assert.assertNull(parsedSrc.getBuild());
}
use of org.jboss.galleon.universe.FeaturePackLocation in project galleon by wildfly.
the class FeaturePackLocationStringTestCase method testProducerWithoutUniverseToString.
@Test
public void testProducerWithoutUniverseToString() throws Exception {
final ProducerSpec producer = new FeaturePackLocation(new UniverseSpec("factory", null), "producer", "channel", "frequency", "build").getProducer();
Assert.assertEquals("producer@factory", producer.toString());
}
use of org.jboss.galleon.universe.FeaturePackLocation in project galleon by wildfly.
the class FeaturePackLocationStringTestCase method testProducerWithUniverseLocationToString.
@Test
public void testProducerWithUniverseLocationToString() throws Exception {
final ProducerSpec producer = new FeaturePackLocation(new UniverseSpec("factory", "location"), "producer", "channel", "frequency", "build").getProducer();
Assert.assertEquals("producer@factory(location)", producer.toString());
}
use of org.jboss.galleon.universe.FeaturePackLocation in project galleon by wildfly.
the class FeaturePackLocationStringTestCase method testMavenUniverseLocationFromString.
@Test
public void testMavenUniverseLocationFromString() throws Exception {
final FeaturePackLocation parsedCoords = FeaturePackLocation.fromString("wildfly@maven(org.jboss.galleon-universe:jboss-galleon-universe:1.0.0.Final):14/beta#14.0.0.Beta1-SNAPSHOT");
Assert.assertNotNull(parsedCoords);
Assert.assertEquals("maven", parsedCoords.getUniverse().getFactory());
Assert.assertEquals("org.jboss.galleon-universe:jboss-galleon-universe:1.0.0.Final", parsedCoords.getUniverse().getLocation());
Assert.assertEquals("wildfly", parsedCoords.getProducerName());
Assert.assertEquals("14", parsedCoords.getChannelName());
Assert.assertEquals("beta", parsedCoords.getFrequency());
Assert.assertEquals("14.0.0.Beta1-SNAPSHOT", parsedCoords.getBuild());
}
use of org.jboss.galleon.universe.FeaturePackLocation in project galleon by wildfly.
the class FeaturePackLocationStringTestCase method testGactvFromString.
@Test
public void testGactvFromString() throws Exception {
final FeaturePackLocation parsedSrc = FeaturePackLocation.fromString("groupId:artifactId:classifier:type:version");
Assert.assertNotNull(parsedSrc);
Assert.assertEquals("maven", parsedSrc.getUniverse().getFactory());
Assert.assertNull(parsedSrc.getUniverse().getLocation());
Assert.assertEquals("groupId:artifactId:classifier:type", parsedSrc.getProducerName());
Assert.assertNull(parsedSrc.getChannelName());
Assert.assertNull(parsedSrc.getFrequency());
Assert.assertEquals("version", parsedSrc.getBuild());
}
Aggregations