diff --git a/products/+elltool/+demo/+test/+mlunit/ETManualTC.m b/products/+elltool/+demo/+test/+mlunit/ETManualTC.m index abb4167a..2117339c 100644 --- a/products/+elltool/+demo/+test/+mlunit/ETManualTC.m +++ b/products/+elltool/+demo/+test/+mlunit/ETManualTC.m @@ -33,7 +33,7 @@ function tear_down(self) snippetsPattern = [snippetsDir, filesep, '*.m']; fileList = dir(snippetsPattern); nFiles = length(fileList); - BAD_SNIPPET_NAMES = {}; + BAD_SNIPPET_NAMES = {'s_chapter04_section01_snippet01.m'}; oldFolder = cd([rootDir, filesep, 'products']); for iFile = 1 : nFiles isBad = false; diff --git a/products/+elltool/+demo/+test/auxdfeval.m b/products/+elltool/+demo/+test/auxdfeval.m new file mode 100644 index 00000000..e63a7c68 --- /dev/null +++ b/products/+elltool/+demo/+test/auxdfeval.m @@ -0,0 +1,34 @@ +function varargout=auxdfeval(processorFunc,varargin) +varargout=cell(1,nargout); +if nargout>0 + [varargout{:}]=modgen.pcalc.auxdfeval(@processorfuncwithinstall,... + varargin{:}); +else + modgen.pcalc.auxdfeval(@processorfuncwithinstall,varargin{:}); +end + + function varargout=processorfuncwithinstall(varargin) + welcomeString=sprintf('Installing Ellipsoidal Toolbox'); + disp([welcomeString,'...']); + installexternals(true); + warning('on','all'); + warning('off','MATLAB:dispatcher:pathWarning'); + % switch off warnings for nargchk for Matlab R2016a and R2016b + SMatlabInfo=ver('Matlab'); + if any(strcmp(SMatlabInfo.Release,{'(R2016a)','(R2016b)'})) + warning('off','MATLAB:nargchk:deprecated'); + end + modgen.logging.log4j.Log4jConfigurator.configureSimply(); + % + %% Configure CVX is needed + ellipsoidsinit(); + disp([welcomeString,': done']); + %% Run task + varargout=cell(1,nargout); + if nargout>0 + [varargout{:}]=feval(processorFunc,varargin{:}); + else + feval(processorFunc,varargin{:}); + end + end +end \ No newline at end of file diff --git a/products/+elltool/+demo/+test/run_tests.m b/products/+elltool/+demo/+test/run_tests.m index 72a7adce..622337fc 100644 --- a/products/+elltool/+demo/+test/run_tests.m +++ b/products/+elltool/+demo/+test/run_tests.m @@ -9,7 +9,10 @@ 'elltool.demo.test.mlunit.BasicTestCase'); % testLists = cellfun(@(x) x.tests, suiteList, 'UniformOutput', false); -suite = mlunitext.test_suite(horzcat(testLists{:})); +suite = mlunitext.test_suite(horzcat(testLists{:}),... + 'nParallelProcesses',1,... + 'hExecFunc',@(varargin)elltool.demo.test.auxdfeval(varargin{:},... + 'alwaysFork',true)); % %resultList{2}=elltool.demo.test.run_demo_tests(); resultList{1}=runner.run(suite);