You are viewing a plain text version of this content. The canonical link for it is here.
Posted to ivy-commits@incubator.apache.org by xa...@apache.org on 2007/01/09 22:09:53 UTC
svn commit: r494617 - in /incubator/ivy/trunk/test/java/org/apache/ivy/ant:
IvyRetrieveTest.java ivy-381.xml
Author: xavier
Date: Tue Jan 9 14:09:52 2007
New Revision: 494617
URL: http://svn.apache.org/viewvc?view=rev&rev=494617
Log:
IVY-381: add a junit test
Added:
incubator/ivy/trunk/test/java/org/apache/ivy/ant/ivy-381.xml
Modified:
incubator/ivy/trunk/test/java/org/apache/ivy/ant/IvyRetrieveTest.java
Modified: incubator/ivy/trunk/test/java/org/apache/ivy/ant/IvyRetrieveTest.java
URL: http://svn.apache.org/viewvc/incubator/ivy/trunk/test/java/org/apache/ivy/ant/IvyRetrieveTest.java?view=diff&rev=494617&r1=494616&r2=494617
==============================================================================
--- incubator/ivy/trunk/test/java/org/apache/ivy/ant/IvyRetrieveTest.java (original)
+++ incubator/ivy/trunk/test/java/org/apache/ivy/ant/IvyRetrieveTest.java Tue Jan 9 14:09:52 2007
@@ -22,8 +22,11 @@
import junit.framework.TestCase;
+import org.apache.ivy.ModuleDescriptor;
+import org.apache.ivy.RetrieveTest;
import org.apache.ivy.ant.IvyResolve;
import org.apache.ivy.ant.IvyRetrieve;
+import org.apache.ivy.report.ResolveReport;
import org.apache.ivy.util.IvyPatternHelper;
import org.apache.tools.ant.BuildException;
import org.apache.tools.ant.Project;
@@ -80,6 +83,16 @@
"org1", "mod1.2", "2.0", "mod1.2", "jar", "jar")).exists());
}
+ public void testRetrievePrivateWithWildcard() throws Exception {
+ _project.setProperty("ivy.dep.file", "test/java/org/apache/ivy/ant/ivy-381.xml");
+ _retrieve.setConf("*");
+ _retrieve.execute();
+ assertTrue(new File(IvyPatternHelper.substitute(RETRIEVE_PATTERN,
+ "org1", "mod1.2", "1.1", "mod1.2", "jar", "jar", "public")).exists());
+ assertTrue(new File(IvyPatternHelper.substitute(RETRIEVE_PATTERN,
+ "org3", "mod3.2", "1.4", "mod3.2", "jar", "jar", "private")).exists());
+ }
+
public void testInline() throws Exception {
// we first resolve another ivy file
IvyResolve resolve = new IvyResolve();
Added: incubator/ivy/trunk/test/java/org/apache/ivy/ant/ivy-381.xml
URL: http://svn.apache.org/viewvc/incubator/ivy/trunk/test/java/org/apache/ivy/ant/ivy-381.xml?view=auto&rev=494617
==============================================================================
--- incubator/ivy/trunk/test/java/org/apache/ivy/ant/ivy-381.xml (added)
+++ incubator/ivy/trunk/test/java/org/apache/ivy/ant/ivy-381.xml Tue Jan 9 14:09:52 2007
@@ -0,0 +1,11 @@
+<ivy-module version="1.0">
+ <info organisation="apache" module="381"/>
+ <configurations>
+ <conf name="public" />
+ <conf name="private" visibility="private" />
+ </configurations>
+ <dependencies>
+ <dependency org="org1" name="mod1.2" rev="1.1" conf="public->default"/>
+ <dependency org="org3" name="mod3.2" rev="1.4" conf="private->default"/>
+ </dependencies>
+</ivy-module>