* Bug #7769 fixed - get_function_path didn't have an unit test.
[scilab.git] / scilab / modules / functions / tests / unit_tests / get_function_path.tst
1 // =============================================================================
2 // Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
3 // Copyright (C) 2013 - Scilab Enterprises - Charlotte HECQUET
4 //
5 //  This file is distributed under the same license as the Scilab package.
6 // =============================================================================
7
8 // <-- CLI SHELL MODE -->
9
10 // unit tests for get_function_path() function
11 // =============================================================================
12
13 assert_checkequal(get_function_path('abcd'),SCI+'/modules/cacsd/macros/abcd.sci');
14 assert_checkequal(get_function_path('dae'),SCI+'/modules/differential_equations/macros/dae.sci');
15 assert_checkequal(get_function_path('acosd'),SCI+'/modules/elementary_functions/macros/acosd.sci');
16 assert_checkequal(get_function_path('dir'),SCI+'/modules/fileio/macros/dir.sci');
17 assert_checkequal(get_function_path('get_function_path'),SCI+'/modules/functions/macros/get_function_path.sci');
18 assert_checkequal(get_function_path('get_param'),SCI+'/modules/parameters/macros/get_param.sci');
19 assert_checkequal(get_function_path('median'),SCI+'/modules/statistics/macros/median.sci');
20 assert_checkequal(get_function_path('calendar'),SCI+'/modules/time/macros/calendar.sci');
21
22 assert_checkequal(get_function_path('eigs.sci'),[]);
23 assert_checkfalse(execstr("get_function_path()","errcatch")==0);
24 assert_checkfalse(execstr("get_function_path(eigs)","errcatch")==0);