Mercurial > hg > octave-nkf
annotate test/fntests.m @ 12469:0ee8d7d60c82
Use single quotes around regexp patterns.
author | Rik <octave@nomad.inbox5.com> |
---|---|
date | Tue, 22 Feb 2011 12:45:30 -0800 |
parents | e4dbfe3019b1 |
children | 890af1cf0a86 |
rev | line source |
---|---|
11523 | 1 ## Copyright (C) 2005-2011 David Bateman |
7016 | 2 ## |
3 ## This file is part of Octave. | |
4 ## | |
5 ## Octave is free software; you can redistribute it and/or modify it | |
6 ## under the terms of the GNU General Public License as published by | |
7 ## the Free Software Foundation; either version 3 of the License, or (at | |
8 ## your option) any later version. | |
9 ## | |
10 ## Octave is distributed in the hope that it will be useful, but | |
11 ## WITHOUT ANY WARRANTY; without even the implied warranty of | |
12 ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | |
13 ## General Public License for more details. | |
14 ## | |
15 ## You should have received a copy of the GNU General Public License | |
16 ## along with Octave; see the file COPYING. If not, see | |
17 ## <http://www.gnu.org/licenses/>. | |
18 | |
5590 | 19 clear all; |
20 | |
5840 | 21 global files_with_no_tests = {}; |
5845 | 22 global files_with_tests = {}; |
5590 | 23 global topsrcdir; |
6257 | 24 global topbuilddir; |
5590 | 25 |
26 currdir = canonicalize_file_name ("."); | |
27 | |
28 if (nargin == 1) | |
5781 | 29 xdir = argv(){1}; |
5590 | 30 else |
31 xdir = "."; | |
32 endif | |
33 | |
34 srcdir = canonicalize_file_name (xdir); | |
35 topsrcdir = canonicalize_file_name (fullfile (xdir, "..")); | |
6257 | 36 topbuilddir = canonicalize_file_name (fullfile (currdir, "..")); |
5590 | 37 |
38 if (strcmp (currdir, srcdir)) | |
39 testdirs = {srcdir}; | |
40 else | |
41 testdirs = {currdir, srcdir}; | |
42 endif | |
43 | |
44 src_tree = canonicalize_file_name (fullfile (topsrcdir, "src")); | |
6257 | 45 liboctave_tree = canonicalize_file_name (fullfile (topsrcdir, "liboctave")); |
5590 | 46 script_tree = canonicalize_file_name (fullfile (topsrcdir, "scripts")); |
6257 | 47 local_script_tree = canonicalize_file_name (fullfile (currdir, "../scripts")); |
48 | |
6162 | 49 fundirs = {src_tree, liboctave_tree, script_tree}; |
5590 | 50 |
6257 | 51 if (! strcmp (currdir, srcdir)) |
52 fundirs{end+1} = local_script_tree; | |
53 endif | |
54 | |
5836 | 55 function print_test_file_name (nm) |
56 filler = repmat (".", 1, 55-length (nm)); | |
57 printf (" %s %s", nm, filler); | |
58 endfunction | |
59 | |
60 function print_pass_fail (n, p) | |
61 if (n > 0) | |
62 printf (" PASS %4d/%-4d", p, n); | |
63 nfail = n - p; | |
64 if (nfail > 0) | |
65 printf (" FAIL %d", nfail); | |
66 endif | |
67 endif | |
7762 | 68 puts ("\n"); |
5836 | 69 endfunction |
70 | |
11024
fa56fd98c0c5
Remove requirement for PCRE in Octave. (Bug #31025)
Rik <octave@nomad.inbox5.com>
parents:
11019
diff
changeset
|
71 function retval = has_functions (f) |
10220
04f2b4d68eba
test/fntests.m (hasfunctions): assume .m files have functions
John W. Eaton <jwe@octave.org>
parents:
10112
diff
changeset
|
72 n = length (f); |
04f2b4d68eba
test/fntests.m (hasfunctions): assume .m files have functions
John W. Eaton <jwe@octave.org>
parents:
10112
diff
changeset
|
73 if (n > 3 && strcmp (f((end-2):end), ".cc")) |
04f2b4d68eba
test/fntests.m (hasfunctions): assume .m files have functions
John W. Eaton <jwe@octave.org>
parents:
10112
diff
changeset
|
74 fid = fopen (f); |
11024
fa56fd98c0c5
Remove requirement for PCRE in Octave. (Bug #31025)
Rik <octave@nomad.inbox5.com>
parents:
11019
diff
changeset
|
75 if (fid >= 0) |
10220
04f2b4d68eba
test/fntests.m (hasfunctions): assume .m files have functions
John W. Eaton <jwe@octave.org>
parents:
10112
diff
changeset
|
76 str = fread (fid, "*char")'; |
04f2b4d68eba
test/fntests.m (hasfunctions): assume .m files have functions
John W. Eaton <jwe@octave.org>
parents:
10112
diff
changeset
|
77 fclose (fid); |
12462
e4dbfe3019b1
Use PCRE regular expressions throughout Octave.
Rik <octave@nomad.inbox5.com>
parents:
11523
diff
changeset
|
78 retval = ! isempty (regexp (str,'^(DEFUN|DEFUN_DLD)\b', 'lineanchors')); |
11024
fa56fd98c0c5
Remove requirement for PCRE in Octave. (Bug #31025)
Rik <octave@nomad.inbox5.com>
parents:
11019
diff
changeset
|
79 else |
fa56fd98c0c5
Remove requirement for PCRE in Octave. (Bug #31025)
Rik <octave@nomad.inbox5.com>
parents:
11019
diff
changeset
|
80 error ("fopen failed: %s", f); |
10220
04f2b4d68eba
test/fntests.m (hasfunctions): assume .m files have functions
John W. Eaton <jwe@octave.org>
parents:
10112
diff
changeset
|
81 endif |
04f2b4d68eba
test/fntests.m (hasfunctions): assume .m files have functions
John W. Eaton <jwe@octave.org>
parents:
10112
diff
changeset
|
82 elseif (n > 2 && strcmp (f((end-1):end), ".m")) |
11024
fa56fd98c0c5
Remove requirement for PCRE in Octave. (Bug #31025)
Rik <octave@nomad.inbox5.com>
parents:
11019
diff
changeset
|
83 retval = true; |
9742
9f8ff01abc65
.cc files are now included in the list of files requiring
Rik <rdrider0-list@yahoo.com>
parents:
9741
diff
changeset
|
84 else |
11024
fa56fd98c0c5
Remove requirement for PCRE in Octave. (Bug #31025)
Rik <octave@nomad.inbox5.com>
parents:
11019
diff
changeset
|
85 retval = false; |
9742
9f8ff01abc65
.cc files are now included in the list of files requiring
Rik <rdrider0-list@yahoo.com>
parents:
9741
diff
changeset
|
86 endif |
9f8ff01abc65
.cc files are now included in the list of files requiring
Rik <rdrider0-list@yahoo.com>
parents:
9741
diff
changeset
|
87 endfunction |
9f8ff01abc65
.cc files are now included in the list of files requiring
Rik <rdrider0-list@yahoo.com>
parents:
9741
diff
changeset
|
88 |
11024
fa56fd98c0c5
Remove requirement for PCRE in Octave. (Bug #31025)
Rik <octave@nomad.inbox5.com>
parents:
11019
diff
changeset
|
89 function retval = has_tests (f) |
5840 | 90 fid = fopen (f); |
11024
fa56fd98c0c5
Remove requirement for PCRE in Octave. (Bug #31025)
Rik <octave@nomad.inbox5.com>
parents:
11019
diff
changeset
|
91 if (fid >= 0) |
8699
6e764b7317bd
test/fntests.m, scripts/test/demo.m: error on fopen failures
John W. Eaton <jwe@octave.org>
parents:
8423
diff
changeset
|
92 str = fread (fid, "*char")'; |
6e764b7317bd
test/fntests.m, scripts/test/demo.m: error on fopen failures
John W. Eaton <jwe@octave.org>
parents:
8423
diff
changeset
|
93 fclose (fid); |
12469
0ee8d7d60c82
Use single quotes around regexp patterns.
Rik <octave@nomad.inbox5.com>
parents:
12462
diff
changeset
|
94 retval = ! isempty (regexp (str, '^%!(test|assert|error|warning)', "lineanchors")); |
11024
fa56fd98c0c5
Remove requirement for PCRE in Octave. (Bug #31025)
Rik <octave@nomad.inbox5.com>
parents:
11019
diff
changeset
|
95 else |
fa56fd98c0c5
Remove requirement for PCRE in Octave. (Bug #31025)
Rik <octave@nomad.inbox5.com>
parents:
11019
diff
changeset
|
96 error ("fopen failed: %s", f); |
8699
6e764b7317bd
test/fntests.m, scripts/test/demo.m: error on fopen failures
John W. Eaton <jwe@octave.org>
parents:
8423
diff
changeset
|
97 endif |
5840 | 98 endfunction |
99 | |
7243 | 100 function [dp, dn, dxf, dsk] = run_test_dir (fid, d); |
5845 | 101 global files_with_tests; |
5840 | 102 global files_with_no_tests; |
5836 | 103 lst = dir (d); |
7243 | 104 dp = dn = dxf = dsk = 0; |
5836 | 105 for i = 1:length (lst) |
5590 | 106 nm = lst(i).name; |
5836 | 107 if (length (nm) > 5 && strcmp (nm(1:5), "test_") |
11033
d9c8916bb9dd
Untabify a few remaining .m scripts.
Rik <octave@nomad.inbox5.com>
parents:
11032
diff
changeset
|
108 && strcmp (nm((end-1):end), ".m")) |
10026
9b3a100922a6
fntests.m: use regexp instead of findstr and only recognize tests that are the first thing on a line
John W. Eaton <jwe@octave.org>
parents:
9742
diff
changeset
|
109 p = n = xf = sk = 0; |
5845 | 110 ffnm = fullfile (d, nm); |
11024
fa56fd98c0c5
Remove requirement for PCRE in Octave. (Bug #31025)
Rik <octave@nomad.inbox5.com>
parents:
11019
diff
changeset
|
111 if (has_tests (ffnm)) |
11033
d9c8916bb9dd
Untabify a few remaining .m scripts.
Rik <octave@nomad.inbox5.com>
parents:
11032
diff
changeset
|
112 print_test_file_name (nm); |
d9c8916bb9dd
Untabify a few remaining .m scripts.
Rik <octave@nomad.inbox5.com>
parents:
11032
diff
changeset
|
113 [p, n, xf, sk] = test (nm(1:(end-2)), "quiet", fid); |
d9c8916bb9dd
Untabify a few remaining .m scripts.
Rik <octave@nomad.inbox5.com>
parents:
11032
diff
changeset
|
114 print_pass_fail (n, p); |
d9c8916bb9dd
Untabify a few remaining .m scripts.
Rik <octave@nomad.inbox5.com>
parents:
11032
diff
changeset
|
115 files_with_tests(end+1) = ffnm; |
5840 | 116 else |
11033
d9c8916bb9dd
Untabify a few remaining .m scripts.
Rik <octave@nomad.inbox5.com>
parents:
11032
diff
changeset
|
117 files_with_no_tests(end+1) = ffnm; |
5840 | 118 endif |
5836 | 119 dp += p; |
5590 | 120 dn += n; |
6730 | 121 dxf += xf; |
7243 | 122 dsk += sk; |
5590 | 123 endif |
124 endfor | |
125 endfunction | |
126 | |
7243 | 127 function [dp, dn, dxf, dsk] = run_test_script (fid, d); |
5845 | 128 global files_with_tests; |
5840 | 129 global files_with_no_tests; |
5781 | 130 global topsrcdir; |
6257 | 131 global topbuilddir; |
5836 | 132 lst = dir (d); |
7243 | 133 dp = dn = dxf = dsk = 0; |
5836 | 134 for i = 1:length (lst) |
5590 | 135 nm = lst(i).name; |
5836 | 136 if (lst(i).isdir && ! strcmp (nm, ".") && ! strcmp (nm, "..") |
11227
84846912f3c1
test/fntests.m: run tests for deprecated functions
John W. Eaton <jwe@octave.org>
parents:
11054
diff
changeset
|
137 && ! strcmp (nm, "CVS")) |
7243 | 138 [p, n, xf, sk] = run_test_script (fid, [d, "/", nm]); |
5590 | 139 dp += p; |
140 dn += n; | |
6730 | 141 dxf += xf; |
7243 | 142 dsk += sk; |
5590 | 143 endif |
144 endfor | |
5836 | 145 for i = 1:length (lst) |
5590 | 146 nm = lst(i).name; |
10112
fddfebeeb33a
Run tests in all *.cc files.
David Grundberg <davidg@cs.umu.se>
parents:
10026
diff
changeset
|
147 ## Ignore hidden files |
fddfebeeb33a
Run tests in all *.cc files.
David Grundberg <davidg@cs.umu.se>
parents:
10026
diff
changeset
|
148 if (nm(1) == '.') |
fddfebeeb33a
Run tests in all *.cc files.
David Grundberg <davidg@cs.umu.se>
parents:
10026
diff
changeset
|
149 continue |
fddfebeeb33a
Run tests in all *.cc files.
David Grundberg <davidg@cs.umu.se>
parents:
10026
diff
changeset
|
150 endif |
9742
9f8ff01abc65
.cc files are now included in the list of files requiring
Rik <rdrider0-list@yahoo.com>
parents:
9741
diff
changeset
|
151 f = fullfile (d, nm); |
9f8ff01abc65
.cc files are now included in the list of files requiring
Rik <rdrider0-list@yahoo.com>
parents:
9741
diff
changeset
|
152 if ((length (nm) > 2 && strcmp (nm((end-1):end), ".m")) || |
10112
fddfebeeb33a
Run tests in all *.cc files.
David Grundberg <davidg@cs.umu.se>
parents:
10026
diff
changeset
|
153 (length (nm) > 3 && strcmp (nm((end-2):end), ".cc"))) |
6730 | 154 p = n = xf = 0; |
5590 | 155 ## Only run if it contains %!test, %!assert %!error or %!warning |
11024
fa56fd98c0c5
Remove requirement for PCRE in Octave. (Bug #31025)
Rik <octave@nomad.inbox5.com>
parents:
11019
diff
changeset
|
156 if (has_tests (f)) |
11033
d9c8916bb9dd
Untabify a few remaining .m scripts.
Rik <octave@nomad.inbox5.com>
parents:
11032
diff
changeset
|
157 tmp = strrep (f, [topsrcdir, "/"], ""); |
d9c8916bb9dd
Untabify a few remaining .m scripts.
Rik <octave@nomad.inbox5.com>
parents:
11032
diff
changeset
|
158 tmp = strrep (tmp, [topbuilddir, "/"], "../"); |
d9c8916bb9dd
Untabify a few remaining .m scripts.
Rik <octave@nomad.inbox5.com>
parents:
11032
diff
changeset
|
159 print_test_file_name (tmp); |
d9c8916bb9dd
Untabify a few remaining .m scripts.
Rik <octave@nomad.inbox5.com>
parents:
11032
diff
changeset
|
160 [p, n, xf, sk] = test (f, "quiet", fid); |
d9c8916bb9dd
Untabify a few remaining .m scripts.
Rik <octave@nomad.inbox5.com>
parents:
11032
diff
changeset
|
161 print_pass_fail (n, p); |
d9c8916bb9dd
Untabify a few remaining .m scripts.
Rik <octave@nomad.inbox5.com>
parents:
11032
diff
changeset
|
162 dp += p; |
d9c8916bb9dd
Untabify a few remaining .m scripts.
Rik <octave@nomad.inbox5.com>
parents:
11032
diff
changeset
|
163 dn += n; |
d9c8916bb9dd
Untabify a few remaining .m scripts.
Rik <octave@nomad.inbox5.com>
parents:
11032
diff
changeset
|
164 dxf += xf; |
d9c8916bb9dd
Untabify a few remaining .m scripts.
Rik <octave@nomad.inbox5.com>
parents:
11032
diff
changeset
|
165 dsk += sk; |
d9c8916bb9dd
Untabify a few remaining .m scripts.
Rik <octave@nomad.inbox5.com>
parents:
11032
diff
changeset
|
166 files_with_tests(end+1) = f; |
11024
fa56fd98c0c5
Remove requirement for PCRE in Octave. (Bug #31025)
Rik <octave@nomad.inbox5.com>
parents:
11019
diff
changeset
|
167 elseif (has_functions (f)) |
11033
d9c8916bb9dd
Untabify a few remaining .m scripts.
Rik <octave@nomad.inbox5.com>
parents:
11032
diff
changeset
|
168 ## To reduce the list length, only mark .cc files that contain |
d9c8916bb9dd
Untabify a few remaining .m scripts.
Rik <octave@nomad.inbox5.com>
parents:
11032
diff
changeset
|
169 ## DEFUN definitions. |
d9c8916bb9dd
Untabify a few remaining .m scripts.
Rik <octave@nomad.inbox5.com>
parents:
11032
diff
changeset
|
170 files_with_no_tests(end+1) = f; |
5590 | 171 endif |
172 endif | |
173 endfor | |
5667 | 174 ## printf("%s%s -> passes %d of %d tests\n", ident, d, dp, dn); |
5590 | 175 endfunction |
176 | |
5836 | 177 function printf_assert (varargin) |
5590 | 178 global _assert_printf; |
5836 | 179 _assert_printf = cat (2, _assert_printf, sprintf (varargin{:})); |
5590 | 180 endfunction |
181 | |
5836 | 182 function ret = prog_output_assert (str) |
5590 | 183 global _assert_printf; |
5836 | 184 if (isempty (_assert_printf)) |
185 ret = isempty (str); | |
5590 | 186 elseif (_assert_printf(end) == "\n") |
5836 | 187 ret = strcmp (_assert_printf(1:(end-1)), str); |
5590 | 188 else |
5836 | 189 ret = strcmp (_assert_printf, str); |
5590 | 190 endif |
191 _assert_printf = ""; | |
192 endfunction | |
193 | |
7645
734854f21c94
fntests.m: report number .m and .cc files without tests separately
John W. Eaton <jwe@octave.org>
parents:
7300
diff
changeset
|
194 function n = num_elts_matching_pattern (lst, pat) |
734854f21c94
fntests.m: report number .m and .cc files without tests separately
John W. Eaton <jwe@octave.org>
parents:
7300
diff
changeset
|
195 n = 0; |
734854f21c94
fntests.m: report number .m and .cc files without tests separately
John W. Eaton <jwe@octave.org>
parents:
7300
diff
changeset
|
196 for i = 1:length (lst) |
11024
fa56fd98c0c5
Remove requirement for PCRE in Octave. (Bug #31025)
Rik <octave@nomad.inbox5.com>
parents:
11019
diff
changeset
|
197 if (! isempty (regexp (lst{i}, pat, "once"))) |
7645
734854f21c94
fntests.m: report number .m and .cc files without tests separately
John W. Eaton <jwe@octave.org>
parents:
7300
diff
changeset
|
198 n++; |
734854f21c94
fntests.m: report number .m and .cc files without tests separately
John W. Eaton <jwe@octave.org>
parents:
7300
diff
changeset
|
199 endif |
734854f21c94
fntests.m: report number .m and .cc files without tests separately
John W. Eaton <jwe@octave.org>
parents:
7300
diff
changeset
|
200 endfor |
734854f21c94
fntests.m: report number .m and .cc files without tests separately
John W. Eaton <jwe@octave.org>
parents:
7300
diff
changeset
|
201 endfunction |
734854f21c94
fntests.m: report number .m and .cc files without tests separately
John W. Eaton <jwe@octave.org>
parents:
7300
diff
changeset
|
202 |
734854f21c94
fntests.m: report number .m and .cc files without tests separately
John W. Eaton <jwe@octave.org>
parents:
7300
diff
changeset
|
203 function report_files_with_no_tests (with, without, typ) |
734854f21c94
fntests.m: report number .m and .cc files without tests separately
John W. Eaton <jwe@octave.org>
parents:
7300
diff
changeset
|
204 pat = cstrcat ("\\", typ, "$"); |
734854f21c94
fntests.m: report number .m and .cc files without tests separately
John W. Eaton <jwe@octave.org>
parents:
7300
diff
changeset
|
205 n_with = num_elts_matching_pattern (with, pat); |
734854f21c94
fntests.m: report number .m and .cc files without tests separately
John W. Eaton <jwe@octave.org>
parents:
7300
diff
changeset
|
206 n_without = num_elts_matching_pattern (without, pat); |
734854f21c94
fntests.m: report number .m and .cc files without tests separately
John W. Eaton <jwe@octave.org>
parents:
7300
diff
changeset
|
207 n_tot = n_with + n_without; |
734854f21c94
fntests.m: report number .m and .cc files without tests separately
John W. Eaton <jwe@octave.org>
parents:
7300
diff
changeset
|
208 printf ("\n%d (of %d) %s files have no tests.\n", n_without, n_tot, typ); |
734854f21c94
fntests.m: report number .m and .cc files without tests separately
John W. Eaton <jwe@octave.org>
parents:
7300
diff
changeset
|
209 endfunction |
734854f21c94
fntests.m: report number .m and .cc files without tests separately
John W. Eaton <jwe@octave.org>
parents:
7300
diff
changeset
|
210 |
5836 | 211 pso = page_screen_output (); |
212 warn_state = warning ("query", "quiet"); | |
213 warning ("on", "quiet"); | |
5590 | 214 try |
5836 | 215 page_screen_output (0); |
11227
84846912f3c1
test/fntests.m: run tests for deprecated functions
John W. Eaton <jwe@octave.org>
parents:
11054
diff
changeset
|
216 warning ("off", "Octave:deprecated-functions"); |
5836 | 217 fid = fopen ("fntests.log", "wt"); |
5590 | 218 if (fid < 0) |
5836 | 219 error ("could not open fntests.log for writing"); |
5590 | 220 endif |
5836 | 221 test ("", "explain", fid); |
7243 | 222 dp = dn = dxf = dsk = 0; |
7762 | 223 puts ("\nIntegrated test scripts:\n\n"); |
5836 | 224 for i = 1:length (fundirs) |
7243 | 225 [p, n, xf, sk] = run_test_script (fid, fundirs{i}); |
5836 | 226 dp += p; |
227 dn += n; | |
6730 | 228 dxf += xf; |
7243 | 229 dsk += sk; |
5590 | 230 endfor |
7762 | 231 puts ("\nFixed test scripts:\n\n"); |
5836 | 232 for i = 1:length (testdirs) |
7243 | 233 [p, n, xf, sk] = run_test_dir (fid, testdirs{i}); |
5836 | 234 dp += p; |
235 dn += n; | |
6730 | 236 dxf += xf; |
7243 | 237 dsk += sk; |
5590 | 238 endfor |
5836 | 239 printf ("\nSummary:\n\n PASS %6d\n", dp); |
5667 | 240 nfail = dn - dp; |
241 printf (" FAIL %6d\n", nfail); | |
6730 | 242 if (dxf > 0) |
7291 | 243 if (dxf > 1) |
7300 | 244 t1 = "were"; |
245 t2 = "failures"; | |
7291 | 246 else |
247 t1 = "was"; | |
248 t2 = "failure"; | |
249 endif | |
250 printf ("\nThere %s %d expected %s (see fntests.log for details).\n", | |
11033
d9c8916bb9dd
Untabify a few remaining .m scripts.
Rik <octave@nomad.inbox5.com>
parents:
11032
diff
changeset
|
251 t1, dxf, t2); |
11054
3b8817c91e31
fntests.m: Break output text differently for better readability.
Rik <octave@nomad.inbox5.com>
parents:
11033
diff
changeset
|
252 puts ("\nExpected failures are known bugs. Please help improve Octave\n"); |
3b8817c91e31
fntests.m: Break output text differently for better readability.
Rik <octave@nomad.inbox5.com>
parents:
11033
diff
changeset
|
253 puts ("by contributing fixes for them.\n"); |
6730 | 254 endif |
7243 | 255 if (dsk > 0) |
9696
01a1fd9167e0
Fix typo directing users to the wrong log file
Rik <rdrider0-list@yahoo.com>
parents:
8920
diff
changeset
|
256 printf ("\nThere were %d skipped tests (see fntests.log for details).\n", dsk); |
11054
3b8817c91e31
fntests.m: Break output text differently for better readability.
Rik <octave@nomad.inbox5.com>
parents:
11033
diff
changeset
|
257 puts ("Skipped tests are features that are disabled in this version of Octave\n"); |
3b8817c91e31
fntests.m: Break output text differently for better readability.
Rik <octave@nomad.inbox5.com>
parents:
11033
diff
changeset
|
258 puts ("because the needed libraries were not present when Octave was built.\n"); |
7243 | 259 endif |
260 | |
7645
734854f21c94
fntests.m: report number .m and .cc files without tests separately
John W. Eaton <jwe@octave.org>
parents:
7300
diff
changeset
|
261 report_files_with_no_tests (files_with_tests, files_with_no_tests, ".m"); |
734854f21c94
fntests.m: report number .m and .cc files without tests separately
John W. Eaton <jwe@octave.org>
parents:
7300
diff
changeset
|
262 report_files_with_no_tests (files_with_tests, files_with_no_tests, ".cc"); |
734854f21c94
fntests.m: report number .m and .cc files without tests separately
John W. Eaton <jwe@octave.org>
parents:
7300
diff
changeset
|
263 |
9710
519e164dde1e
Fix typo of an extra space in instructions to user
Rik <rdrider0-list@yahoo.com>
parents:
9696
diff
changeset
|
264 puts ("\nPlease help improve Octave by contributing tests for\n"); |
10899
686e3bc432a2
fntests.m: Add extra newline for more readable output during make.
Rik <octave@nomad.inbox5.com>
parents:
10220
diff
changeset
|
265 puts ("these files (see the list in the file fntests.log).\n\n"); |
7645
734854f21c94
fntests.m: report number .m and .cc files without tests separately
John W. Eaton <jwe@octave.org>
parents:
7300
diff
changeset
|
266 |
5840 | 267 fprintf (fid, "\nFiles with no tests:\n\n%s", |
11033
d9c8916bb9dd
Untabify a few remaining .m scripts.
Rik <octave@nomad.inbox5.com>
parents:
11032
diff
changeset
|
268 list_in_columns (files_with_no_tests, 80)); |
5836 | 269 fclose (fid); |
7645
734854f21c94
fntests.m: report number .m and .cc files without tests separately
John W. Eaton <jwe@octave.org>
parents:
7300
diff
changeset
|
270 |
5836 | 271 page_screen_output (pso); |
272 warning (warn_state.state, "quiet"); | |
5590 | 273 catch |
5836 | 274 page_screen_output (pso); |
275 warning (warn_state.state, "quiet"); | |
276 disp (lasterr ()); | |
5590 | 277 end_try_catch |