you can use TRXER tool to generate HTML reports from trx file. Download TrxerConsole.exe file from here
- Build/Rebuild the project to create .dll file.
- If your project name is UnitTest1 then the .dll file name will be UnitTest1.dll. Go to the location of .dll like
C:\Users\NAME\source\repos\UnitTest1 \UnitTest1 \bin\Debug\netcoreapp3.1\UnitTest1.dll
- Open Developer command prompt of Visual studio 2019
- Run command to set the location
cd C:\Users\NAME\source\repos\UnitTest1\UnitTest1\bin\Debug\netcoreapp3.1\UnitTest1.dll
- Run the Command to Generate trx file:
vstest.console.exe UnitTest1.dll /logger:trx
-
Trx file will be generated in the folder TestReults which is present in the same location where project dll file is present.
-
If TrxerConsole.exe is in downloads then run the command to convert into HTML.
Path of trxerconsole.exe file then space then Path of trxfile as below
C:\Users\NAME\Downloads\TrxerConsole.exe C:\Users\NAME\source\repos\DesktopWithMSTest\DesktopWithMSTest\bin\Debug\netcoreapp3.1\TestResults\TestResult.trx
- HTML file will be generated in same TestResults Folder.
link to refer
your Reports will look like:
标签:exe,NAME,报告,导出,dll,will,MSTest,file,UnitTest1 From: https://www.cnblogs.com/z45281625/p/18006013