1% Test if divand is working correctly.
2
3tests = {...
4   'test_interp_1d',...
5   'test_interp_2d',...
6   'test_interp_regular',...
7   'test_sparse_diff',...
8   'test_1dvar',...
9   'test_2dvar',...
10   'test_2dvar_check',...
11   'test_2dvar_adv',...
12   'test_2dvar_rellen',...
13   'test_2dvar_lenxy',...
14   'test_2dvar_check_correrr',...
15   'test_2dvar_pcg',...
16   'test_2dvar_constrain',...
17   'test_2dvar_cyclic',...
18   'test_2dvar_eof_check',...
19   'test_3dvar',...
20    'test_3dvar_large_stacked',...
21   'test_4dvar'};
22
23% disable warning for full matrice product
24state = warning('query','divand:fullmat');
25warning('off','divand:fullmat')
26
27for iindex=1:length(tests);
28
29  fprintf('run %s: ',tests{iindex});
30  try
31    eval(tests{iindex});
32    colordisp('  OK  ','green');
33  catch
34    colordisp(' FAIL ','red');
35    disp(lasterr)
36  end
37end
38
39% restore warning state
40warning(state.state,'divand:fullmat')
41
42% Copyright (C) 2014 Alexander Barth <a.barth@ulg.ac.be>
43%
44% This program is free software; you can redistribute it and/or modify it under
45% the terms of the GNU General Public License as published by the Free Software
46% Foundation; either version 2 of the License, or (at your option) any later
47% version.
48%
49% This program is distributed in the hope that it will be useful, but WITHOUT
50% ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
51% FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
52% details.
53%
54% You should have received a copy of the GNU General Public License along with
55% this program; if not, see <http://www.gnu.org/licenses/>.
56