ant-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From maart...@apache.org
Subject svn commit: r961022 - in /ant/ivy/core/branches/2.2.x: ./ src/java/org/apache/ivy/plugins/parser/xml/ test/java/org/apache/ivy/plugins/parser/xml/
Date Tue, 06 Jul 2010 21:45:40 GMT
Author: maartenc
Date: Tue Jul  6 21:45:40 2010
New Revision: 961022

URL: http://svn.apache.org/viewvc?rev=961022&view=rev
Log:
Merged fix for IVY-1203 into the 2.2.x branch.

Added:
    ant/ivy/core/branches/2.2.x/test/java/org/apache/ivy/plugins/parser/xml/test-write-extends.xml
      - copied unchanged from r961020, ant/ivy/core/trunk/test/java/org/apache/ivy/plugins/parser/xml/test-write-extends.xml
Modified:
    ant/ivy/core/branches/2.2.x/   (props changed)
    ant/ivy/core/branches/2.2.x/CHANGES.txt
    ant/ivy/core/branches/2.2.x/src/java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorWriter.java
    ant/ivy/core/branches/2.2.x/test/java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorWriterTest.java

Propchange: ant/ivy/core/branches/2.2.x/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Tue Jul  6 21:45:40 2010
@@ -1,4 +1,4 @@
 /ant/ivy/core/branches/2.0.0:727187-727188,727520-732505
 /ant/ivy/core/branches/2.0.0-rc2:707459-708717
 /ant/ivy/core/branches/2.0.x:696803-698317
-/ant/ivy/core/trunk:695737,696014-696031,696442,958415-958693
+/ant/ivy/core/trunk:695737,696014-696031,696442,958415-958693,961017-961020

Modified: ant/ivy/core/branches/2.2.x/CHANGES.txt
URL: http://svn.apache.org/viewvc/ant/ivy/core/branches/2.2.x/CHANGES.txt?rev=961022&r1=961021&r2=961022&view=diff
==============================================================================
--- ant/ivy/core/branches/2.2.x/CHANGES.txt (original)
+++ ant/ivy/core/branches/2.2.x/CHANGES.txt Tue Jul  6 21:45:40 2010
@@ -106,6 +106,10 @@ for detailed view of each issue, please 
 	Jaroslaw Wypychowski
 	Aleksey Zhukov
 	
+   2.2.0
+=====================================
+- FIX: Ivy info/extends/extendsType attribute is misspelled by XmlModuleDescriptorWriter
(IVY-1203) (thanks to Jason Trump)
+
    2.2.0-rc1
 =====================================
 - DOCUMENTATION: Limit the width of running text in documentation (IVY-1030)

Modified: ant/ivy/core/branches/2.2.x/src/java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorWriter.java
URL: http://svn.apache.org/viewvc/ant/ivy/core/branches/2.2.x/src/java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorWriter.java?rev=961022&r1=961021&r2=961022&view=diff
==============================================================================
--- ant/ivy/core/branches/2.2.x/src/java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorWriter.java
(original)
+++ ant/ivy/core/branches/2.2.x/src/java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorWriter.java
Tue Jul  6 21:45:40 2010
@@ -476,7 +476,7 @@ public final class XmlModuleDescriptorWr
                 if (location != null) {
                     out.print(" location=\"" + XMLHelper.escape(location) + "\"");
                 }
-                out.print(" extendTypes=\"" + StringUtils.join(parent.getExtendsTypes(),
",") + "\"");
+                out.print(" extendType=\"" + StringUtils.join(parent.getExtendsTypes(), ",")
+ "\"");
                 out.println("/>");
             }
             License[] licenses = md.getLicenses();

Modified: ant/ivy/core/branches/2.2.x/test/java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorWriterTest.java
URL: http://svn.apache.org/viewvc/ant/ivy/core/branches/2.2.x/test/java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorWriterTest.java?rev=961022&r1=961021&r2=961022&view=diff
==============================================================================
--- ant/ivy/core/branches/2.2.x/test/java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorWriterTest.java
(original)
+++ ant/ivy/core/branches/2.2.x/test/java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorWriterTest.java
Tue Jul  6 21:45:40 2010
@@ -26,6 +26,7 @@ import java.util.GregorianCalendar;
 
 import junit.framework.TestCase;
 
+import org.apache.ivy.Ivy;
 import org.apache.ivy.core.module.descriptor.DefaultModuleDescriptor;
 import org.apache.ivy.core.module.descriptor.ModuleDescriptor;
 import org.apache.ivy.core.module.id.ModuleRevisionId;
@@ -106,6 +107,20 @@ public class XmlModuleDescriptorWriterTe
         assertEquals(expected, wrote);
     }
 
+	public void testExtends() throws Exception {
+		ModuleDescriptor md = XmlModuleDescriptorParser.getInstance().parseDescriptor(
+		    new IvySettings(), XmlModuleDescriptorWriterTest.class.getResource("test-extends-all.xml"),
false);
+		XmlModuleDescriptorWriter.write(md, LICENSE, dest);
+
+		assertTrue(dest.exists());
+		String wrote = FileUtil.readEntirely(new BufferedReader(new FileReader(dest)))
+				.replaceAll("\r\n?", "\n");
+		String expected = readEntirely("test-write-extends.xml")
+				.replaceAll("\r\n?", "\n")
+				.replaceAll("working@localhost", Ivy.getWorkingRevision());
+		assertEquals(expected, wrote);
+	}
+
     private String readEntirely(String resource) throws IOException {
         return FileUtil.readEntirely(new BufferedReader(new InputStreamReader(
                 XmlModuleDescriptorWriterTest.class.getResource(resource).openStream())));



Mime
View raw message