Mercurial > hg > octave-lyh
changeset 12864:213c791292a6
test: Add 3 tests for string_fill_char()
* pt-mat.cc: Add 3 tests for string_fill_char()
author | Rik <octave@nomad.inbox5.com> |
---|---|
date | Tue, 19 Jul 2011 13:35:18 -0700 |
parents | 8f9702abe3e3 |
children | a4d1581f9e72 |
files | src/pt-mat.cc |
diffstat | 1 files changed, 5 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/src/pt-mat.cc +++ b/src/pt-mat.cc @@ -1149,9 +1149,12 @@ /* %!error (string_fill_char (1, 2)); -%!test +%% string_fill_char() function call must be outside of %!test block +%% due to the way a %!test block is wrapped inside a function +%!shared orig_val, old_val %! orig_val = string_fill_char (); -%! old_val = string_fill_char ("X"); +%! old_val = string_fill_char ("X"); +%!test %! assert (orig_val, old_val); %! assert (string_fill_char (), "X"); %! assert (["these"; "are"; "strings"], ["theseXX"; "areXXXX"; "strings"]);