Main Content


Generate simulation or execution options for slvnvruntest or slvnvruncgvtest


runOpts = slvnvruntestopts generates a runOpts structure for slvnvruntest.


runOpts = slvnvruntestopts('cgv')es a runOpts structure for slvnvruncgvtest.


collapse all

% Create runOpts objects for slvnvruntest
runtest_opts = slvnvruntestopts;

% Create runOpts objects for slvnvruncgvtest
runcgvtest_opts = slvnvruntestopts('cgv')

Output Arguments

collapse all

runOpts can have the following fields. If you do not specify a field, slvnvruncgvtest or slvnvruntest uses the default value.

Field NameDescription

Test case index array to simulate or execute from data file.

If testIdx = [], all test cases are simulated or executed.

Default: []


Available only for slvnvruntest.

Specifies the format of signal logging data for signals that connect to the outport of the model and for intermediate signals that are configured for logging.

If you specify Dataset, data is stored in the Simulink.SimulationData.Dataset objects.

Default: 'Dataset'


Available only for slvnvruntest.

If true, slvnvruntest collects model coverage data during simulation.

Default: false


Available only for slvnvruntest.

cvtest object for collecting model coverage.

If coverageSetting is [], slvnvruntest uses the coverage settings for the model specified in the call to slvnvruntest.

Default: []


Available only for slvnvruncgvtest.

If you have not configured your model to execute test cases with the CGV API, this field specifies creating and configuring the model.

If true and you have not configured the model to execute test cases with the CGV API, slvnvruncgvtest copies the model, fixes the configuration, and executes the test cases on the copied model.

If false, an error occurs if the tests cannot execute with the CGV API.


If you have not configured the top-level model or any referenced models to execute test cases, slvnvruncgvtest does not copy the model, even if allowCopyModel is true. An error occurs.



Available only for slvnvruncgvtest.

Defines the software-in-the-loop (SIL) or processor-in-the-loop (PIL) approach for CGV:

  • 'topmodel'

  • 'modelblock'



Available only for slvnvruncgvtest.

Specifies mode of execution for CGV:

  • 'sim'

  • 'sil'

  • 'pil'



Available only for slvnvruntest.

If true, Simulink® Coverage™ uses fast restart mode for model simulation.

Default: true


Available only for slvnvruntest.

If true, Simulink Coverage simulates test cases with parallel computing. This option requires a Parallel Computing Toolbox™ license.

Default: false

Version History

Introduced in R2010b