Commit Graph
64 Commits
Author SHA1 Message Date
Atsushi Eno c225d87477 2009-02-10 Atsushi Enomoto <[email protected]>
* XmlTextWriter2.cs : similar fix in WriteStartElement() to
	  previous change. Fixed bug #474091.

	* XmlTextWriterTests.cs : added test for bug #474091.


svn path=/trunk/mcs/; revision=126417
2009-02-10 04:09:27 +00:00
Atsushi Eno fbda9fbe5d 2009-02-06 Atsushi Enomoto <[email protected]>
* XmlTextWriter2.cs : in WriteStartAttribute(), fill namespace in
	  case it is null and the prefix has matching ns. Fixed bug #472634.

	* XmlTextWriterTests.cs : added test for bug #472634.


svn path=/trunk/mcs/; revision=126047
2009-02-06 14:13:28 +00:00
Atsushi Eno 28bfedcf61 2007-09-27 Atsushi Enomoto <[email protected]>
* XmlWriter.cs : implemented WriteValue(object) based on
	  MSDN "Writing Typed Data" with some fix.
	  http://msdn2.microsoft.com/en-us/library/bft97s8e(VS.80).aspx
	* XmlTextWriter.cs : state check is extraneous. It caused unexpected
	  rejection of empty namespace URI.

	* XmlWriterTests.cs : added test for WriteValue(object).
	* XmlTextWriterTests.cs : added WriteQualifiedName() test with empty
	  namespace.


svn path=/trunk/mcs/; revision=86483
2007-09-27 11:39:15 +00:00
Atsushi Eno d543ed0b78 2006-09-01 Atsushi Enomoto <[email protected]>
* XmlTextWriter2.cs : expect atomized names only when it is
	  appropriate. Fixed bug #79047.

	* XmlTextWriterTests.cs : added test for bug #79047


svn path=/trunk/mcs/; revision=64676
2006-09-01 05:21:48 +00:00
Atsushi Eno fc826ee0c8 2006-08-10 Atsushi Enomoto <[email protected]>
* XmlTextWriter2.cs : more indentation fixes. Now I believe it is
	  almost MS compat, but it won't help poor Mike.

	* XmlTextWriterTests.cs : more indentation tests.


svn path=/trunk/mcs/; revision=63574
2006-08-10 05:56:02 +00:00
Atsushi Eno e8adca21e7 2006-08-07 Atsushi Enomoto <[email protected]>
* XmlTextWriter2.cs : WriteBinHex() is allowed at Attribute state.
	  Fixed bug #79019.

	* XmlTextWriterTests.cs : test for #79019.


svn path=/trunk/mcs/; revision=63422
2006-08-07 03:36:21 +00:00
Atsushi Eno 93c714b33f 2006-07-28 Atsushi Enomoto <[email protected]>
* XmlTextWriter2.cs : fixed some indentation bugs: comments and PIs
	  should not cause indentation override like text, cdata and
	  whitespaces do.
	  Fixed some error messages on node kind.
	* XmlTextWriter.cs, XmlTextWriterOpenElement.cs : removed old code.
	  (I don't want to remove old great code but it confused mike today.)

	* XmlTextWriterTests.cs : added test case for comments, PIs and
	  indentation.


svn path=/trunk/mcs/; revision=63079
2006-07-28 15:45:18 +00:00
Atsushi Eno 234edcaeed 2006-06-08 Atsushi Enomoto <[email protected]>
* XmlTextWriter2.cs : if an attribute being written has the same
	  non-empty namespace URI as current default namespace, its prefix
	  should be written. Fixed bug #78598.

	* XmlTextWriterTests.cs : added test for bug #78598.


svn path=/trunk/mcs/; revision=61550
2006-06-08 02:39:12 +00:00
Atsushi Eno a301e7e1da 2006-04-21 Atsushi Enomoto <[email protected]>
* XmlTextWriter.cs : fix for bug #78148. set_Formatting() is not
	  rejected after writing some content. I totally disagree on that
	  it should be allowed, but here is the fix.

	* XmlTextWriterTests.cs : test for bug #78148.


svn path=/trunk/mcs/; revision=59722
2006-04-21 02:29:45 +00:00
Atsushi Eno 9275dc19bf 2006-02-24 Atsushi Enomoto <[email protected]>
* XmlTextWriter2.cs :
	  WriteRaw() has stupid second arg. Fixed bug #77623.
	  WriteString() should raise an error when it is called immediately
	  after WriteStartDocument().

	* XmlTextWriterTests.cs : added test for bug #77623. Also fixed
	  WriteString() test which failed to fail (Assert.Fail).


svn path=/trunk/mcs/; revision=57229
2006-02-24 06:58:11 +00:00
Atsushi Eno 578b26de8c 2006-02-22 Atsushi Enomoto <[email protected]>
* XmlChar.cs : (IndexOfInvalidChar) fixed surrogate pairs handling.
	  They were always regarded as invalid.
	* XmlTextWriter2.cs : seems like MS XmlTextWriter outputs invalid
	  characters as character references. It totally does not make sense
	  but corcompare depended on that behavior.

	  This "compatibility" fix causes 10% or more performance loss!!!

	* XmlTextWriterTests.cs : added invalid character processing test.


svn path=/trunk/mcs/; revision=57145
2006-02-22 07:05:20 +00:00
Atsushi Eno 9eb523dd9f 2006-02-21 Atsushi Enomoto <[email protected]>
* XmlNamespaceManager.cs : added internal LookupPrefixExclusive()
	  which discards "overriden" namespaces.
	* XmlTextWriter2.cs : fresh implementation.
	  - The source structure is simplified and cleaner.
	  - When outputting escaped string, output directly to TextWriter.
	  - roughly 20% performance improvement.

	  (Also fixed previous perf. evaluation excess in ChangeLog.)


	* XmlReaderCommonTests.cs : added custom assertion overload that takes
	  test label.
	* XmlNodeReaderTests.cs : labeled some.
	* XmlTextWriterTests.cs :
	  Changed the semantics of AttributeNamespacesXmlnsXmlns() and
	  removed NotDotNet (in contrast this test should fail with previous
	  version of XmlTextWriter). See the code comment for details.
	  Added WriteQualifiedNameXmlnsError().


	* System.Xml.dll.sources : removed XmlTextWriterOpenElement.cs and 
	  XmlTextWriter.cs. Added XmlTextWriter2.cs, to be renamed to
	  XmlTextWriter.cs in a few days or weeks.


svn path=/trunk/mcs/; revision=57095
2006-02-21 15:39:10 +00:00
Atsushi Eno dc2376e29c 2006-02-14 Atsushi Enomoto <[email protected]>
* XmlTextWriterTests.cs : tiny test name fix, as it does not actually
	  test WriteString().


svn path=/trunk/mcs/; revision=56843
2006-02-14 03:45:44 +00:00
Atsushi Eno f99e279c01 2006-02-14 Atsushi Enomoto <[email protected]>
* XmlTextWriter.cs : WriteRaw("") is not simply ignored but process
	  state check and closes open tag.

	* XmlTextWriterTests.cs : added test WriteRaw("") closes open tag.


svn path=/trunk/mcs/; revision=56842
2006-02-14 03:44:18 +00:00
Atsushi Eno 8701dd6372 2006-02-14 Atsushi Enomoto <[email protected]>
* XmlTextWriterTests.cs : numbered some tests and added some comments.


svn path=/trunk/mcs/; revision=56840
2006-02-14 03:23:14 +00:00
Atsushi Eno 5d8f9644c4 2006-01-13 Atsushi Enomoto <[email protected]>
* XmlTextWriter.cs : Fixed bug #77082.
	  When the state was Start, after WriteProcessingInstruction() and
	  WriteWhitespace() change it to Prolog.
	  After WriteDocType() set state to WriteState.Element.

	* XmlTextWriterTests.cs : added some tests for XMLdecl state check.

	* XslTransformTests.cs : Output_Indent_Xml_DocType() is working now.


svn path=/trunk/mcs/; revision=55487
2006-01-13 05:03:39 +00:00
Atsushi Eno e2e89695a1 2006-01-12 Atsushi Enomoto <[email protected]>
* XmlTextWriter.cs : Do not local duplicate of automatically-created
	  prefixes (i.e. check local autocreated prefixes other than
	  namespaces from ancestors). Fixed bug #77086 and #77087.

	* XmlTextWriterTests.cs : Split AutoCreatePrefixes() and marked as
	  Ignore rather than NotWorking. Also it is not for bug #77086 and
	  #77077 (they were fixed). See bug #77088.


svn path=/trunk/mcs/; revision=55418
2006-01-12 06:03:06 +00:00
Atsushi Eno d2efba1d17 2006-01-12 Atsushi Enomoto <[email protected]>
* XmlWriter.cs : use XmlChar.IsNmToken() to check argument and throw
	  ArgumentException in WriteNmTokenInternal().

	* XmlTextWriterTests.cs : re-enabled WriteNmToken_InvalidChars().


svn path=/trunk/mcs/; revision=55415
2006-01-12 05:04:09 +00:00
Atsushi Eno 1ca0a71ebf 2006-01-12 Atsushi Enomoto <[email protected]>
* XmlTextWriter.cs : Fixed bug #77094. Only XmlTextWriter checks
	  such invalid "xml" prefix which is being mapped to different
	  namespace URI than the predefined one.
	  Removed comment that does not make sense.
	* XmlNamespaceManager.cs : IsValidDeclaration() could be private.
	  Added some comments.

	* XmlTextWriterTests.cs : re-enabled bug #77094 related tests.


svn path=/trunk/mcs/; revision=55414
2006-01-12 04:47:39 +00:00
Gert Driesen cd7644c997 * XmlTextWriter.cs: Modified WriteWhitespace to throw ArgumentException
if value is null or zero-length string. Modified WriteNmToken to throw
ArgumentException if name is null or zero-length string. Cosmetic
change to WriteStringInternal.
* XmlElement.cs: In 2.0 profile, do not throw ArgumentNullException
if new value for Prefix is null.
* XmlElementTests.cs: Improved tests for setting prefix to null
or zero-length string. On 2.0 profile, setting prefix to null should
not result in ArgumentNullException.
* XmlTextWriterTests.cs: Enabled WriteNmToken tests and
WriteWhitespace tests for null or zero-length value.

svn path=/trunk/mcs/; revision=55115
2006-01-05 20:16:41 +00:00
Atsushi Eno 565db0ae52 2006-01-05 Atsushi Enomoto <[email protected]>
* XmlTextWriterTests.cs : removed silly part from
	  WriteStartElement_XmlPrefix (). We are not reproducing MS bugs.
	  (kept remaining part of this test; see if it makes sense after
	  bug #77094 got fixed).


svn path=/trunk/mcs/; revision=55091
2006-01-05 04:31:31 +00:00
Gert Driesen 980e2e28e0 * XmlTextWriterTests.cs: Do not yet enable tests for WriteWhitespace
with null or zero-length value (await approval for XmlTextWriter
change from Atsushi).

svn path=/trunk/mcs/; revision=54914
2005-12-29 18:45:36 +00:00
Gert Driesen 7e110d0cc3 * XmlTextWriterTests.cs: Do not yet enable tests for WriteNmToken
with null or zero-length value (await approval for XmlTextWriter
change from Atsushi).

svn path=/trunk/mcs/; revision=54868
2005-12-27 11:23:36 +00:00
Gert Driesen 18476997c6 * XmlTextWriterTests.cs: Added tests for WriteWhitespace and WriteNmToken.
svn path=/trunk/mcs/; revision=54867
2005-12-27 11:17:32 +00:00
Gert Driesen 2ff0bdf8d2 * XmlTextWriterTests.cs: Allow all tests to pass on .NET 1.1.
svn path=/trunk/mcs/; revision=54859
2005-12-27 08:37:50 +00:00
Atsushi Eno 1bdcf7c5fa 2005-12-26 Atsushi Enomoto <[email protected]>
* XmlTextWriter.cs : when namespaceURI is String.Empty, Prefix
          should be just ignored (it is likely to happen that DOM nodes
          with empty namespace URI are specified non-empty prefix by
          users, which had better be just ignored). Fixed bug #77095.

        * XmlTextWriterTests.cs : enabled
          WriteStartElement_Prefix_EmptyNamespace() and
          NamespacesPrefixWithEmptyAndNullNamespaceEmpty().


svn path=/trunk/mcs/; revision=54850
2005-12-26 14:57:23 +00:00
Gert Driesen 0d9de1f66b * XmlTextWriterTests.cs: Renamed tests to avoid ambiguity, and
renumbered some tests. Added tests for WriteStartElement and
WriteElementString for zero-length and null local names.
Added tests for bugs #77093, #77094 and #77095.

svn path=/trunk/mcs/; revision=54846
2005-12-26 12:39:40 +00:00
Atsushi Eno 61ccf99f78 2005-12-23 Atsushi Enomoto <[email protected]>
* XmlTextWriter.cs : When xml:space or xml:lang attribute was
	  directly written without an element, it caused ArgumentOutOfRange.
	  Fixed bug #77084.

	* XmlTextWriterTests.cs : XmlSpace_Valid() is working now.


svn path=/trunk/mcs/; revision=54793
2005-12-23 20:14:56 +00:00
Atsushi Eno a2f89ee36f 2005-12-23 Atsushi Enomoto <[email protected]>
* XmlTextWriter.cs : (WriteStartAttribute) set prefix as "xmlns" when
	  namespaceURI is that of xmlns attributes.

	* XmlTextWriterTests.cs : XmlNs_Valid2() is working now.


svn path=/trunk/mcs/; revision=54792
2005-12-23 20:04:42 +00:00
Gert Driesen d356e20cd7 * XmlTextWriterTests.cs: Fixed line endings. Enabled XmlPrefix_ValidMS
test. Added bug numbers to test cases.

svn path=/trunk/mcs/; revision=54784
2005-12-23 17:57:40 +00:00
Gert Driesen f42513507a * XmlTextWriterTests.cs: Improved coverage of xml prefix tests.
* XsltCompileExceptionTests.cs: Added tests for ctors.
* XsltExceptionTests.cs: Added tests for ctors.
* XslTransformTests.cs: Added tests for validation of <xsl:output>
attributes.
* System.Xml_test.dll.sources: Added XsltCompilerExceptionTests.cs and 
XsltExceptionTests.cs.
* IXsltContextFunction.cs: Fixed line endings (all CRLF).
* IXsltContextVariable.cs: Fixed line endings (all CRLF).
* XsltContext.cs: Fixed line endings (all CRLF).
* XsltCompileException.cs: Fixed line endings (all CRLF).
Fixed message to correspond with both MS.NET 1.x and 2.0.
* XslTransform.cs: Fixed line endings (all CRLF).
* XsltArgumentList.cs: Fixed line endings (all CRLF).
* XsltException.cs: Fixed line endings (all CRLF). Fixed message to
correspond with MS.NET 1.x and 2.0.
* XslVariable.cs: Beautify error messages.
* XslElement.cs: Same.
* XslAvt.cs: Same.
* XslAttribute.cs: Same.
* XslApplyTemplates.cs: Same.
* XslTemplateContent.cs: Same.
* XslCallTemplate.cs: Same.
* XslCopy.cs: Same.
* XslChoose.cs: Same.
* ScriptCompilerInfo.cs: Fixed line endings.
* XslStylesheet.cs: Beautify error messages.
* Debug.cs: Fixed line endings.
* XslOutput.cs: Indent is now bool instead of string, use
MoveToAttribute to navigate through attributes instead of using
GetAttribute, as we also need to distinguish attributes with
zero-length value from attributes that are not specified for
correct implementation of DOCTYPE. Implemented validation for
value of "omit-xml-declaration", "standalone" and "indent".
We now throw a XsltCompileException for unknown attribute.
* XmlWriterEmitter.cs: only skip WriteDocType is systemId is null.
* HtmlEmitter.cs: XslOutput.Indent is now bool. Fixed WriteDocType
to match MS.NET.
* XmlDecimalFormat.cs: Beautify error messages.
* XslTemplate.cs: Beautify error messages.
* GenericOutputter.cs: XslOutput.Indent is now bool.
* Compiler.cs: Beautify error messages.

svn path=/trunk/mcs/; revision=54780
2005-12-23 15:32:55 +00:00
Gert Driesen 47e7ed0f0b * XmlTextWriterTests.cs: Fixed some tests that caught exception to
become useful. Added few tests that fail on Mono.

svn path=/trunk/mcs/; revision=54535
2005-12-16 17:04:28 +00:00
Gert Driesen 18d58db8f5 * XmlTextWriterTests.cs: No longer derive from deprecated Assertion
class. Added WriteDocType tests.
* XmlWriterTests.cs: No longer derive from deprecated Assertion class.

svn path=/trunk/mcs/; revision=54531
2005-12-16 14:06:42 +00:00
Konstantin Triger 231afa731c allow null string in WriteCData
svn path=/trunk/mcs/; revision=54441
2005-12-15 10:18:32 +00:00
Atsushi Eno bfa4dfa209 2005-10-23 Atsushi Enomoto <[email protected]>
* XmlTextWriter.cs : throw InvalidOperationException if any of
	  WriteBlah() methods were invoked at error state.

	* XmlTextWriterTests.cs : split some tests that try to write nodes
	  at error state (.NET 2.0 correctly rejects them).


svn path=/trunk/mcs/; revision=52100
2005-10-23 19:48:22 +00:00
Atsushi Eno fd3a4d2430 2005-09-14 Atsushi Enomoto <[email protected]>
* XmlTextWriter.cs : for surrogate pair, output character
        * reference
          as a single character instead of two reference pairs. Fixed
bug #76095.
          Patch by Brion Vibber.

        * XmlTextWriterTests.cs : added #76095 testcase.


svn path=/trunk/mcs/; revision=49997
2005-09-14 01:44:27 +00:00
Atsushi Eno 764efc74fe 2005-07-14 Atsushi Enomoto <[email protected]>
* XmlTextWriter.cs : In WriteQualifiedName(), when there is open
	  attribute, it calls LookupPrefix() and then if namespace was empty,
	  it resulted in an exception. Fixed bug #75546.

	* XmlTextWriterTests.cs : added bug #75546 testcase.


svn path=/trunk/mcs/; revision=47312
2005-07-14 16:49:36 +00:00
Atsushi Eno 47bd90b0c3 2005-03-25 Atsushi Enomoto <[email protected]>
* XmlTextWriterTests.cs : added more test case for xml:space.


svn path=/trunk/mcs/; revision=42248
2005-03-25 11:37:19 +00:00
Atsushi Eno c8d5ac5a2d 2005-03-24 Atsushi Enomoto <[email protected]>
* XmlWriter.cs : WriteQualifiedName() should check namespace validity
	  (whether it is in scope or not).
	* XmlTextWriter.cs : When WriteQualifiedName() is invoked inside
	  attribute and no matching namespace declaration, create prefix
	  on demand. Code reused from WriteStartAttribute().

	* XmlTextWriterTests.cs : added more tests on WriteQualifiedName().


svn path=/trunk/mcs/; revision=42189
2005-03-24 05:59:50 +00:00
Atsushi Eno cd668536eb 2005-03-03 Atsushi Enomoto <[email protected]>
* XmlTextWriter.cs : For duplicating namespace mapping, it should
	  create another prefix without throwing an exception.

	* XmlTextWriterTests.cs : added testcase for duplicating namespace 
	  mapping processing (should create another prefix, not exception).


svn path=/trunk/mcs/; revision=41387
2005-03-03 09:25:16 +00:00
Atsushi Eno 5527fe3ce9 2005-03-02 Atsushi Enomoto <[email protected]>
* XmlTextWriter.cs : LookupPrefix() should not return those prefix
	  that is overriden by another xmlns declaration.

	* XmlTextWriterTests.cs : Added test for LookupPrefix() for
	  overriden prefix.


svn path=/trunk/mcs/; revision=41372
2005-03-02 19:02:39 +00:00
Atsushi Eno b7a95b1570 2005-02-24 Atsushi Enomoto <[email protected]>
* XmlTextWriter.cs : WriteString() should be valid when 
	  WriteStartDocument() was not called.

	* XmlTextWriterTests.cs : Test for call to WriteRaw() -> WriteString()


svn path=/trunk/mcs/; revision=41159
2005-02-24 14:20:00 +00:00
Atsushi Eno b8267fa659 2005-01-13 Atsushi Enomoto <[email protected]>
* XmlValidatingReaderTests.cs,
	  XmlReaderCommonTests.cs,
	  XmlTextWriterTests.cs,
	  XmlUrlResolverTests.cs :
	  Marked as NotDotNet for those tests that fails under MS.NET.
	  Commented out some XmlTextWriter implementation-dependent assertions.
	  Fixed ResolveUriWithNullArgs () expected return type.



svn path=/trunk/mcs/; revision=38844
2005-01-13 04:26:25 +00:00
Atsushi Eno e857d44273 2005-01-11 Atsushi Enomoto <[email protected]>
* XmlTextWriter.cs : WriteComment() was outputting extraneous EOL.

	* XmlTextWriterTests.cs : added Indent2() to test WriteComment EOL.


svn path=/trunk/mcs/; revision=38702
2005-01-11 16:00:05 +00:00
Atsushi Eno 12792953c0 2004-10-29 Atsushi Enomoto <[email protected]>
* XmlReaderCommonTests.cs : ReadAsObject() is removed.
	* XmlTextWriterTests.cs : added CloseTwice().
	* XmlNodeTests.cs : added labels.

svn path=/trunk/mcs/; revision=35418
2004-10-29 02:07:07 +00:00
Atsushi Eno 357572721d 2004-06-14 Atsushi Enomoto <[email protected]>
* XmlTextWriterTests.cs : Avoid CR/CRLF testing complexity.

svn path=/trunk/mcs/; revision=29492
2004-06-14 10:40:33 +00:00
Atsushi Eno d4e8a093ba 2004-06-06 Atsushi Enomoto <[email protected]>
* XmlTextWriterTests.cs : Added indentation testcase (it might now
	  work due to CompareInfo.IndexOf() bug).

svn path=/trunk/mcs/; revision=28910
2004-06-06 14:50:43 +00:00
Atsushi Eno 261e928b07 2004-05-27 Atsushi Enomoto <[email protected]>
* XmlTextReaderTests.cs : added test for bug #59142.
	* XmlTextWriterTests.cs : added test for bug #59154.
	* XmlDocumentTests.cs : added test for bug #59155.

svn path=/trunk/mcs/; revision=28238
2004-05-27 09:29:47 +00:00
Atsushi Eno 4f981f7a03 2004-01-23 Atsushi Enomoto <[email protected]>
* XmlElementTests.cs : Added SetAttributeXmlns.
	* XmlTextWriterTests.cs : Added several xmlns-related tests.

svn path=/trunk/mcs/; revision=22440
2004-01-23 19:45:56 +00:00
Atsushi Eno bcd924f598 2004-01-22 Atsushi Enomoto <[email protected]>
* XmlTextWriterTests.cs : Added *Do*OutputRemovalDefaultNSDeclaration.

svn path=/trunk/mcs/; revision=22412
2004-01-22 20:21:27 +00:00