Products & Services Solutions Academia Support User Community Company

Learn more about Simulink Verification and Validation   

cvsave - Save coverage tests and results to file

Syntax

cvsave(filename, model)
cvsave(filename, cvto1, cvto2, ...)
cvsave(filename, cvdo1, cvdo2, ...)

Description

cvsave(filename, model) saves all the tests (cvtest objects) and results (cvdata objects) related to model in the text file filename.cvt. model is a handle to or name of a Simulink model.

cvsave(filename, cvto1, cvto2, ...) saves multiple cvtest objects in the text file filename.cvt. cvsave also saves information about any referenced models.

cvsave(filename, cvdo1, cvdo2, ...) saves the tests and test results for multiple cvdata objects to the text file filename.cvt. cvsave also saves information about any referenced models.

Examples

Save coverage results for the slvnvdemo_cv_small_controller model in ratelim_testdata.cvt:

model = 'slvnvdemo_cv_small_controller'; 
open_system(model);
cvt = cvtest(model);
cvd = cvsim(cvt);
cvsave('ratelim_testdata', model);

Alternatives

To save cumulative coverage results:

  1. In the Model Editor, select Tools > Coverage Settings.

  2. On the Results tab:

    1. Select Save cumulative results in workspace variable.

    2. Select Save last run in workspace variable.

  3. Click OK to close the Coverage Settings dialog box.

  4. Simulate the model.

See Also

cvload

How To

  


Related Products & Applications

Learn more about Simulink through this collection of videos, articles, technical literature and the Getting Started with Simulink Guide.

 © 1984-2009- The MathWorks, Inc.    -   Site Help   -   Patents   -   Trademarks   -   Privacy Policy   -   Preventing Piracy   -   RSS