How to convert NUnit output into an HTML report

前端 未结 6 1932
谎友^
谎友^ 2020-12-07 16:58

Does anyone have any suggestions for a good tool, xslt or other that can produce an HTML report from the XML output of NUnit?

We\'re currently using NUnit 2.5.5 to r

相关标签:
6条回答
  • 2020-12-07 17:41

    This looks decent, works with NUnit3, is free and actively maintained as of Sept 2017: https://ghpreporter.github.io/

    Github: https://github.com/GHPReporter/Ghpr.Core

    Sample Report: http://ghpreporter.github.io/report/?currentTab=runs-stats

    0 讨论(0)
  • 2020-12-07 17:43

    ReportUnit is not maintained and is being replaced by extentreports-dotnet-cli.


    You can also try ReportUnit, which also supports Gallio, xUnit, TestNG and MSTest: http://reportunit.relevantcodes.com

    This is a simple exe file that will convert your xml report into an HTML dashboards (samples):

    • Folder-level dashboard: http://relevantcodes.com/Tools/ReportUnit/Index.html
    • File-level: http://relevantcodes.com/Tools/ReportUnit/NUnit-TestResult.html

    Usage:

    reportunit "path-to-folder" // folder-level report
    reportunit "path-to-folder" "output-folder" // folder-level report
    reportunit "Result.xml" "generated.html" // file-level report
    

    More info here: http://reportunit.relevantcodes.com

    0 讨论(0)
  • 2020-12-07 17:44

    For anyone interested, I found two other tools.

    • nunit-summary
    • nunit-results

    Both are available on Lauchpad, linked to from the very basic product pages linked above.

    Unfortunately, neither of these tools provided the required level of detail for our installation - so I ended up doctoring the xslt's that came with nunit2report to suit out needs.

    0 讨论(0)
  • 2020-12-07 17:51

    Looks like this is the most searchable NUnit HTML answer. So for NUnit 3 Allure would be the best option

    https://github.com/allure-framework/allure2 - global repo

    https://github.com/unickq/allure-nunit - for NUnit

    0 讨论(0)
  • 2020-12-07 17:53

    I know this is an old question, but it's the top result in Google on the subject and thought it deserved a mention.. Where I work had the exact same issue so we developed a little app that will parse an XML results file and output a nice looking self-contained HTML page based on bootstrap 3. Code and binaries are available on GitHub. It's responsive as well as we email the reports to mobile devices.

    0 讨论(0)
  • 2020-12-07 18:01

    There's also an 'nunit2report' task in NAntContrib (which was recently updated with the NAnt 0.91 release).

    NAntContrib NUnit2Report Task

    0 讨论(0)
提交回复
热议问题