I have a Simulink test file (.MLDATX), which I would like to extract Parameter Overrides from (and store in a table, for example). How can I do this?
John Williams answered .
2025-11-20
% Load an instance of the test file
testfile = sltest.testmanager.TestFile('./mytestfile.mldatx', false);
% Extract and loop over test suites
testsuites = getTestSuites( testfile );
for suite = testsuites
% Extract and loop over test cases
testcases = getTestCases( suite );
for testcase = testcases
% Extract and loop over parameter sets
paramsets = getParameterSets( testcase );
for paramset = paramsets
% Extract and loop over parameter overrides
paramoverrides = getParameterOverrides ( paramset );
for paramoverride = paramoverrides
% Use the Parameter Overrides
disp( paramoverride.Name )
disp( paramoverride.Value )
end
end
end
end