Ignore:
Timestamp:
Mar 8, 2008, 4:52:01 PM (16 years ago)
Author:
dai
Message:

ActiveBasic.Xml.Parserを仮実装。
・SerializeTestのテストケースを追加。
・SimpleTestCaseにおいて、一時ディレクトリを扱えるようにした。
・XmlTestのテストケースを更新。

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/TestCase/SimpleTestCase/XmlTest.ab

    r444 r465  
    33
    44Sub TestMain()
     5    ' 一時ディレクトリを取得
     6    Dim tempDir = GetExclusiveTempDirPath( "XmlTest" )
     7
    58    Dim doc = New System.Xml.XmlDocument()
    6     doc.AppendChild( doc.CreateXmlDeclaration( "1.0", "UTF-8", Nothing ) )
     9    doc.AppendChild( doc.CreateXmlDeclaration( "1.0", "shift-jis", Nothing ) )
    710    doc.AppendChild( doc.CreateElement( "root" ) )
    811    doc.ChildNodes[1].AppendChild( doc.CreateElement( "test" ) )
     
    1518    doc.ChildNodes[1].Attributes.Add( attr2 )
    1619
    17     System.Diagnostics.Debug.WriteLine( doc.OuterXml() )
     20    ' 書いて
     21    doc.Save( tempDir + "\test.xml" )
     22
     23    ' 読んで
     24    Dim clone = New System.Xml.XmlDocument
     25    clone.Load( tempDir + "\test.xml" )
     26
     27    ' 比較してみる
     28    UnitTest( "XmlTest", doc.OuterXml = clone.OuterXml )
    1829End Sub
    1930
Note: See TracChangeset for help on using the changeset viewer.