diff --git a/_test/test_instrument_classes/test_IX_aperture.m b/_test/test_instrument_classes/test_IX_aperture.m index 1fddd49dc..ac3faf252 100644 --- a/_test/test_instrument_classes/test_IX_aperture.m +++ b/_test/test_instrument_classes/test_IX_aperture.m @@ -7,27 +7,8 @@ %-------------------------------------------------------------------------- function self = test_IX_aperture (varargin) + self@TestCaseWithSave(varargin{:}); test_files_folder = fileparts(mfilename('fullpath')); - if nargin> 0 - is = ismember(varargin,'-save'); - if any(is) - if numel(is)>2 - error('HERBERT:test_IX_apperture:invalid_argument',... - 'the test can be called only with one or two parameters') - elseif numel(is)==1 - filename = 'test_IX_aperture_output.mat'; - else - filename = varargin{~is}; - end - opt = '-save'; - params={opt,filename}; - else - params= varargin(1); - end - else - params= {'test_IX_aperture'}; - end - self@TestCaseWithSave(params{:}); self.home_folder = test_files_folder; %does nothing unless the constructor called with '-save' key self.save() @@ -73,7 +54,7 @@ function test_aperture_array_prev_versions(obj) % 2x2 array example ap_arr = [IX_aperture('Ap0', 11, 0.2, 0.25), IX_aperture('Ap1', 121, 0.22, 0.225);... IX_aperture('Ap3', 311, 0.23, 0.325), IX_aperture('Ap4', 114, 0.24, 0.245)]; - sample_file_location = obj.home_folder; + sample_file_location = obj.home_folder; if obj.save_output % prepare test data for the future. % move test data to data folder manually % run test_IX_apperture with -save option to obtain reference @@ -102,8 +83,8 @@ function test_single_aperture_load_prev_versions(obj) ap = IX_aperture ('Ap0', 11, 0.2, 0.25); sample_files_location = obj.home_folder; if obj.save_output - % run test_IX_apperture with -save option to obtain reference - % files when changed to new class version + % run test_IX_apperture with -save option to obtain reference + % files when changed to new class version save_variables=true; ver = ap.classVersion(); verstr = ['ver',num2str(ver)];