diff --git a/matlab/tests/check_gdatpaths.m b/matlab/tests/check_gdatpaths.m new file mode 100644 index 0000000000000000000000000000000000000000..e208bad433da34cf64471548c066ebad3db23a64 --- /dev/null +++ b/matlab/tests/check_gdatpaths.m @@ -0,0 +1,15 @@ +classdef check_gdatpaths < matlab.unittest.fixtures.Fixture + methods + function setup(fixture) + % caller + oldpwd = pwd; + testfolder = fileparts(fullfile(mfilename('fullpath'))); % relative path w.r.t. this file + cd(testfolder); % go into test folder so you might not see local gdat.m + gdatpath = fileparts(which('gdat')); + cd(oldpwd); + fixture.assertTrue(startsWith(testfolder,gdatpath),... + sprintf('test folder path does not contain path of gdat: %s\n This file is in: %s\n which(''gdat''):\n Please run setpaths_gdat() to set the paths',... + testfolder,which('gdat'))); + end + end +end diff --git a/matlab/tests/test_requestnames.m b/matlab/tests/test_requestnames.m index 1839318c0dec23231fd5da44f555e662238299f9..3c8986c1abc3626e59b0feacedeb6daee7a1c58c 100644 --- a/matlab/tests/test_requestnames.m +++ b/matlab/tests/test_requestnames.m @@ -1,5 +1,5 @@ classdef (SharedTestFixtures={... - check_mds}) ... + check_mds,check_gdatpaths}) ... test_requestnames < matlab.unittest.TestCase properties (Abstract) diff --git a/matlab/tests/test_tcv_get_ids.m b/matlab/tests/test_tcv_get_ids.m index 9ef5a2405b55f17212d4b9c47f431b41b563d47c..9b3065794ce6c82cd995b9afe8bbd309b6914ff0 100644 --- a/matlab/tests/test_tcv_get_ids.m +++ b/matlab/tests/test_tcv_get_ids.m @@ -1,5 +1,5 @@ classdef (SharedTestFixtures={... - check_mds})... + check_mds,check_gdatpaths})... test_tcv_get_ids < matlab.unittest.TestCase properties(TestParameter)