Reputation: 29
I have written BDD for webservices, I have to generate reports for that. So please let me know the step by step creation of testresult.xml
file
Upvotes: 1
Views: 1811
Reputation: 696
With SpecFlow dotnet5 you can generate a trx results file executing:
dotnet test --logger "trx;LogFileName=results.trx"
After that, Instal this tool globally https://github.com/gfoidl/trx2junit
dotnet tool install --global trx2junit --version 2.0.0
Convert that trx file into junit file
trx2junit results.trx
trx2junit (c) gfoidl -- v2.0.0
https://github.com/gfoidl/trx2junit
Converting 1 trx file(s) to JUnit-xml...
Converting 'results.trx' to 'results.xml'
done in 0.0738152 seconds. bye.
The results.xml
is generated with the junit format expected.
Upvotes: 0
Reputation: 29
As per the comments in Specflow nunit test report is blank
i downgraded to nunit framework 2.6.4 ,it worked :)
Upvotes: 0
Reputation: 5835
Have a look at the documentation: http://www.specflow.org/documentation/Reporting/
Upvotes: 1