I'm using vs 2019 enterprise Is it possible to run vs 2019 code analyze by command and not by gui? if yes what command is it? thanks.
I'm using vs 2019 enterprise Is it possible to run vs 2019 code analyze by command and not by gui? if yes what command is it? thanks.
yup, you can using the command /analyze
https://docs.microsoft.com/en-us/cpp/build/reference/analyze-code-analysis?view=msvc-160
After investigation the answer is YES and this is the command:
vstest.console.exe ut.dll /Enablecodecoverage
VSTest.Console.exe is the command-line tool to run tests
ut.dll is the unit test project I want to run
/Enablecodecoverage is the option to run code coverage via cmd.
for more explanation on vstest.console.exe see here