Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/mono.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--mcs/class/System.XML/System.Xml/ChangeLog5
-rw-r--r--mcs/class/System.XML/System.Xml/XmlElement.cs2
-rw-r--r--mcs/class/System.XML/Test/ChangeLog5
-rw-r--r--mcs/class/System.XML/Test/XmlElementTests.cs6
4 files changed, 17 insertions, 1 deletions
diff --git a/mcs/class/System.XML/System.Xml/ChangeLog b/mcs/class/System.XML/System.Xml/ChangeLog
index 81e788b9c70..9be31a65fc1 100644
--- a/mcs/class/System.XML/System.Xml/ChangeLog
+++ b/mcs/class/System.XML/System.Xml/ChangeLog
@@ -1,3 +1,8 @@
+2002-08-16 Jason Diamond <jason@injektilo.org>
+
+ * XmlElement.cs: Fixed writing out qualified elements courtesy of
+ Marcus Bürgel <marcus.buergel@gmx.de>.
+
2002-08-13 Tim Coleman <tim@timcoleman.com>
* XmlTextWriter.cs:
Partial implementation of WriteQualifiedName ().
diff --git a/mcs/class/System.XML/System.Xml/XmlElement.cs b/mcs/class/System.XML/System.Xml/XmlElement.cs
index 6925b8f0dea..67f1070bc96 100644
--- a/mcs/class/System.XML/System.Xml/XmlElement.cs
+++ b/mcs/class/System.XML/System.Xml/XmlElement.cs
@@ -274,7 +274,7 @@ namespace System.Xml
public override void WriteTo (XmlWriter w)
{
- w.WriteStartElement(LocalName);
+ w.WriteStartElement(Prefix, LocalName, NamespaceURI);
foreach(XmlNode attributeNode in Attributes)
attributeNode.WriteTo(w);
diff --git a/mcs/class/System.XML/Test/ChangeLog b/mcs/class/System.XML/Test/ChangeLog
index 37c452924a2..062f6b54410 100644
--- a/mcs/class/System.XML/Test/ChangeLog
+++ b/mcs/class/System.XML/Test/ChangeLog
@@ -1,5 +1,10 @@
2002-08-16 Jason Diamond <jason@injektilo.org>
+ * XmlElementTests.cs: Added test for OuterXml (and WriteTo) for
+ qualified elements.
+
+2002-08-16 Jason Diamond <jason@injektilo.org>
+
* makefile.gnu: Added SOURCES_INCLUDE and SOURCES_EXCLUDE variables
to get tests to build with the new build system.
diff --git a/mcs/class/System.XML/Test/XmlElementTests.cs b/mcs/class/System.XML/Test/XmlElementTests.cs
index fb56e56ac20..58c910cce64 100644
--- a/mcs/class/System.XML/Test/XmlElementTests.cs
+++ b/mcs/class/System.XML/Test/XmlElementTests.cs
@@ -134,5 +134,11 @@ namespace MonoTests.System.Xml
AssertEquals ("val1", element.GetAttribute ("attr1"));
AssertEquals ("val2", element.GetAttribute ("attr2"));
}
+
+ public void TestOuterXmlWithNamespace ()
+ {
+ XmlElement element = document.CreateElement ("foo", "bar", "#foo");
+ AssertEquals ("<foo:bar xmlns:foo=\"#foo\" />", element.OuterXml);
+ }
}
}