Mercurial > octave-nkf
comparison test/test_return.m @ 14131:c3309e1ec50d stable
test: Use Octave coding and spacing conventions for fixed test scripts
* build_bc_overload_tests.sh, build_bc_overloads_expected.m,
build_sparse_tests.sh, test_args.m, test_contin.m, test_diag_perm.m,
test_error.m, test_eval-catch.m, test_for.m, test_func.m, test_global.m,
test_if.m, test_index.m, test_io.m, test_logical_index.m, test_null_assign.m,
test_parser.m, test_prefer.m, test_range.m, test_recursion.m, test_return.m,
test_slice.m, test_struct.m, test_switch.m, test_system.m, test_transpose.m,
test_try.m, test_unwind.m, test_while.m:
Use Octave coding and spacing conventions for fixed test scripts.
author | Rik <octave@nomad.inbox5.com> |
---|---|
date | Sun, 01 Jan 2012 20:04:52 -0800 |
parents | fd0a3ac60b0e |
children | 72c96de7a403 |
comparison
equal
deleted
inserted
replaced
14130:e13bfbc2c4c5 | 14131:c3309e1ec50d |
---|---|
17 ## <http://www.gnu.org/licenses/>. | 17 ## <http://www.gnu.org/licenses/>. |
18 | 18 |
19 %% test/octave.test/return/return-1.m | 19 %% test/octave.test/return/return-1.m |
20 %!function y = f () | 20 %!function y = f () |
21 %! y = 1; | 21 %! y = 1; |
22 %! return | 22 %! return; |
23 %! y = 2; | 23 %! y = 2; |
24 %!assert(f(),1) | 24 %!endfunction |
25 %! | |
26 %!assert(f(), 1) | |
25 | 27 |
26 %% test/octave.test/return/return-2.m | 28 %% test/octave.test/return/return-2.m |
27 %!test | 29 %!test |
28 %! return; | 30 %! return; |
29 | 31 |