Update of /cvsroot/mvp-xml/XInclude/v1/test
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv17141/v1/test
Modified Files:
EntryPoint.cs XIncludeReaderTests.cs XIncludeTest.csproj
Log Message:
Fixed empty base URI bug.
Index: XIncludeTest.csproj
===================================================================
RCS file: /cvsroot/mvp-xml/XInclude/v1/test/XIncludeTest.csproj,v
retrieving revision 1.14
retrieving revision 1.15
diff -u -d -r1.14 -r1.15
--- XIncludeTest.csproj 3 Nov 2004 13:09:35 -0000 1.14
+++ XIncludeTest.csproj 3 Nov 2004 14:17:37 -0000 1.15
@@ -263,6 +263,10 @@
BuildAction = "Content"
/>
<File
+ RelPath = "tests\test-Martin.xml"
+ BuildAction = "Content"
+ />
+ <File
RelPath = "tests\twofallbacks.xml"
BuildAction = "Content"
/>
Index: EntryPoint.cs
===================================================================
RCS file: /cvsroot/mvp-xml/XInclude/v1/test/EntryPoint.cs,v
retrieving revision 1.14
retrieving revision 1.15
diff -u -d -r1.14 -r1.15
--- EntryPoint.cs 3 Nov 2004 12:55:46 -0000 1.14
+++ EntryPoint.cs 3 Nov 2004 14:17:37 -0000 1.15
@@ -9,15 +9,15 @@
{
public static void Main()
{
- //XIncludeReaderTests rt = new XIncludeReaderTests();
+ XIncludeReaderTests rt = new XIncludeReaderTests();
//LTG_Edinburgh_UnivTests rt = new LTG_Edinburgh_UnivTests();
- NISTTests rt = new NISTTests();
+ //NISTTests rt = new NISTTests();
//Elliotte_Rusty_HaroldTests rt = new Elliotte_Rusty_HaroldTests();
//FourThoughtTests rt = new FourThoughtTests();
//XIncludeSyntaxTests rt = new XIncludeSyntaxTests();
try
{
- rt.Nist_include_24();
+ rt.NoBaseURITest();
}
catch (Exception e)
{
Index: XIncludeReaderTests.cs
===================================================================
RCS file: /cvsroot/mvp-xml/XInclude/v1/test/XIncludeReaderTests.cs,v
retrieving revision 1.15
retrieving revision 1.16
diff -u -d -r1.15 -r1.16
--- XIncludeReaderTests.cs 3 Nov 2004 13:09:35 -0000 1.15
+++ XIncludeReaderTests.cs 3 Nov 2004 14:17:37 -0000 1.16
@@ -349,6 +349,21 @@
RunAndCompare("../../tests/test-Martin.xml", "../../results/test-Martin.xml");
}
+ /// <summary>
+ /// Test for string as input (no base URI)
+ /// </summary>
+ [Test]
+ [ExpectedException(typeof(FatalResourceException))]
+ public void NoBaseURITest()
+ {
+ StreamReader sr = new StreamReader("../../tests/document.xml");
+ string xml = sr.ReadToEnd();
+ sr.Close();
+ XIncludingReader xir = new XIncludingReader(new StringReader(xml));
+ XmlTextWriter w = new XmlTextWriter(Console.Out);
+ while (xir.Read());
+ }
+
}
public class TestResolver : XmlUrlResolver
|