matlab(tdcs): report, switch/case entry, runners, README

This commit is contained in:
Experiments DB Dev
2026-07-20 08:00:40 -04:00
parent 27d388530a
commit 01f59a5265
6 changed files with 413 additions and 0 deletions
+14
View File
@@ -0,0 +1,14 @@
%RUN_TESTS Run the full matlab.unittest suite and exit nonzero on failure.
% Usage: matlab -batch "run_tests"
% (add the analysis/matlab directory to the path first if it is not
% already on it, e.g. matlab -batch "addpath('analysis/matlab'); run_tests")
thisDir = fileparts(mfilename('fullpath'));
results = runtests(fullfile(thisDir, 'tests'));
disp(results);
fprintf('PASS=%d FAIL=%d\n', sum([results.Passed]), sum([results.Failed]));
if any([results.Failed])
error('run_tests:failed', 'One or more tests failed.');
end