Imported Upstream version 4.0.0~alpha1

Former-commit-id: 806294f5ded97629b74c85c09952f2a74fe182d9
This commit is contained in:
Jo Shields
2015-04-07 09:35:12 +01:00
parent 283343f570
commit 3c1f479b9d
22469 changed files with 2931443 additions and 869343 deletions

View File

@ -123,34 +123,36 @@ namespace NUnit.ConsoleRunner
Console.WriteLine();
string xmlOutput = CreateXmlOutput( result );
if (options.xmlConsole)
{
Console.WriteLine(xmlOutput);
}
else
{
try
{
//CreateSummaryDocument(xmlOutput, transformReader );
XmlResultTransform xform = new XmlResultTransform( transformReader );
xform.Transform( new StringReader( xmlOutput ), Console.Out );
}
catch( Exception ex )
{
Console.WriteLine( "Error: {0}", ex.Message );
return TRANSFORM_ERROR;
}
}
if (result != null) {
string xmlOutput = CreateXmlOutput( result );
// Write xml output here
string xmlResultFile = options.xml == null || options.xml == string.Empty
? "TestResult.xml" : options.xml;
if (options.xmlConsole)
{
Console.WriteLine(xmlOutput);
}
else
{
try
{
//CreateSummaryDocument(xmlOutput, transformReader );
XmlResultTransform xform = new XmlResultTransform( transformReader );
xform.Transform( new StringReader( xmlOutput ), Console.Out );
}
catch( Exception ex )
{
Console.WriteLine( "Error: {0}", ex.Message );
return TRANSFORM_ERROR;
}
}
using ( StreamWriter writer = new StreamWriter( xmlResultFile ) )
{
writer.Write(xmlOutput);
// Write xml output here
string xmlResultFile = options.xml == null || options.xml == string.Empty
? "TestResult.xml" : options.xml;
using ( StreamWriter writer = new StreamWriter( xmlResultFile ) )
{
writer.Write(xmlOutput);
}
}
//if ( testRunner != null )