Design verifier :run all and produce coverage for a sldvmakeharness created model

1 view (last 30 days)
Jiahao CHANG
Jiahao CHANG on 18 Jun 2020
Commented: Pat Canny on 19 Jun 2020
After I use MATLAB 17b to generate harness model by using 'sldvmakeharness' function, the harness model and its signal builder display successfully.
Normally I will click the 'run all and produce coverage' button in signal builder to test All cases and produce a model coverage report.
Rather than click button, can I produce the coverage report programmly?
I've spend a lot of time to search commands for this but nothing I can found...

Accepted Answer

Pat Canny
Pat Canny on 19 Jun 2020
Edited: Pat Canny on 19 Jun 2020
Hi Jiahao,
I recommend using sldvrun to generate tests with Design Verifier, then sldvruntest to run the tests and cvhtml to generate a report. An example workflow is included in the documentation for sldvruntest, which I've copied here:
opts = sldvoptions;
opts.Mode = 'TestGeneration';
opts.SaveHarnessModel = 'on';
opts.SaveReport = 'off';
[ status, files ] = sldvrun('sldvdemo_cruise_control', opts);
runOpts = sldvruntestopts;
runOpts.coverageEnabled = true;
[ outData,covData ] = sldvruntest('sldvdemo_cruise_control',...
- Pat
Pat Canny
Pat Canny on 19 Jun 2020
You're welcome! Thanks for the feedback on the Documentation improvement. We've tried to improve it over the recent releases. If you come across anything else that is confusing or missing, please let me know.

Sign in to comment.

More Answers (0)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!