from
MATLAB/Simulink Unit Test Framework
by Carl Kritzinger
A unit test framework for matlab and simulink components
|
| unit_test_iterator(source_root_directory)
|
function results = unit_test_iterator(source_root_directory)
% unit_test_iterator - run all the unit tests in the source tree
%
% Inputs:
% source_root_directory - the source tree root
%
% Outputs:
% results - structure containing the details of all results for all unit tests.
%
% Example:
% results = unit_test_iterator('d:\src\')
%
% Other m-files required: none
%
% See also: unit_test, run_unit_test_batch, make_simulink_unit_test
% Author: Carl Kritzinger
% KAT DSP Team
% email address: carl@ska.ac.za
% November 2005
%------------- MAIN --------------
%search through the root directory
test_file_list = file_find(source_root_directory,'-name','_unit_test*.mat');
results = [];
for kk = 1:length(test_file_list)
results = [results; unit_test(test_file_list(kk).name)];
end
|
|
Contact us at files@mathworks.com