开发者

Generating html from Nunit xml test results

I am generating the xml output of nunit tests using:

 nunit-console /xml:console-test.xml nunit.tests.dll

How can I create a table formatted report using the xml. Is there any tool f开发者_Go百科or that?


You can bind xml to a datagrid to display it as a table with a handful of lines of C#.

http://www.csharphelp.com/2006/10/binding-raw-xml-to-a-datagrid-control-in-asp-net/

Something like:

DataSet ds = new DataSet(); 
ds.ReadXml(Server.MapPath("console-test.xml"),XmlReadMode.InferSchema); 
this.DataGrid1.DataSource = ds; 
this.DataGrid1.DataBind();


Or use an XSLT transformer to generate the HTML from the xml.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜