fUnit 0.0.2 → 0.0.3

Sign up to get free protection for your applications and to get access to all the features.
data/Rakefile CHANGED
@@ -1,9 +1,11 @@
1
1
  # Rakefile for fUnit -*- ruby -*-
2
2
  #
3
- # Copyright 2006 United States Government as represented by NASA Langley
4
- # Research Center, Hampton, Virginia.
3
+ # Copyright 2006 United States Government as represented by
4
+ # NASA Langley Research Center. No copyright is claimed in
5
+ # the United States under Title 17, U.S. Code. All Other Rights
6
+ # Reserved.
5
7
  #
6
- # This file is governed by the OSI-approved, NASA Open Source Agreement.
8
+ # This file is governed by the NASA Open Source Agreement.
7
9
  # See COPYING for details.
8
10
 
9
11
  begin
@@ -17,7 +19,7 @@ end
17
19
  require 'rake/testtask'
18
20
  require 'rake/rdoctask'
19
21
 
20
- PKG_VERSION = '0.0.2'
22
+ PKG_VERSION = '0.0.3'
21
23
 
22
24
  PKG_FILES = FileList[
23
25
  '[A-Z]*',
@@ -71,6 +73,8 @@ else
71
73
  fragments into valid Fortran code and compiles, links, and
72
74
  runs them against the module under test.
73
75
  EOF
76
+ s.requirements << 'Registration appreciated -- see fun3d.larc.nasa.gov'
77
+ s.required_ruby_version = '>= 1.8.1'
74
78
  s.rubyforge_project = 'funit'
75
79
  s.require_path = 'lib'
76
80
  s.autorequire = 'funit'
data/bin/funit CHANGED
@@ -1,3 +1,11 @@
1
+ # Copyright 2006 United States Government as represented by
2
+ # NASA Langley Research Center. No copyright is claimed in
3
+ # the United States under Title 17, U.S. Code. All Other Rights
4
+ # Reserved.
5
+ #
6
+ # This file is governed by the NASA Open Source Agreement.
7
+ # See COPYING for details.
8
+
1
9
  begin
2
10
  require 'funit'
3
11
  rescue LoadError
@@ -121,7 +121,7 @@
121
121
  onclick="toggleCode('M000013-source');return false;">[Source]</a></p>
122
122
  <div class="method-source-code" id="M000013-source">
123
123
  <pre>
124
- <span class="ruby-comment cmt"># File lib/funit/assertions.rb, line 42</span>
124
+ <span class="ruby-comment cmt"># File lib/funit/assertions.rb, line 52</span>
125
125
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">isequal</span>(<span class="ruby-identifier">line</span>)
126
126
  <span class="ruby-identifier">line</span><span class="ruby-operator">=~</span><span class="ruby-regexp re">/\((\w+\(.*\)|[^,]+),(.+)\)/</span>
127
127
  <span class="ruby-ivar">@type</span> = <span class="ruby-value str">'IsEqual'</span>
@@ -149,7 +149,7 @@
149
149
  onclick="toggleCode('M000012-source');return false;">[Source]</a></p>
150
150
  <div class="method-source-code" id="M000012-source">
151
151
  <pre>
152
- <span class="ruby-comment cmt"># File lib/funit/assertions.rb, line 33</span>
152
+ <span class="ruby-comment cmt"># File lib/funit/assertions.rb, line 43</span>
153
153
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">isequalwithin</span>(<span class="ruby-identifier">line</span>)
154
154
  <span class="ruby-identifier">line</span><span class="ruby-operator">=~</span><span class="ruby-regexp re">/\(([^,]+),(.+),(.+)\)/</span>
155
155
  <span class="ruby-ivar">@type</span> = <span class="ruby-value str">'IsEqualWithin'</span>
@@ -177,7 +177,7 @@
177
177
  onclick="toggleCode('M000010-source');return false;">[Source]</a></p>
178
178
  <div class="method-source-code" id="M000010-source">
179
179
  <pre>
180
- <span class="ruby-comment cmt"># File lib/funit/assertions.rb, line 15</span>
180
+ <span class="ruby-comment cmt"># File lib/funit/assertions.rb, line 25</span>
181
181
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">isfalse</span>(<span class="ruby-identifier">line</span>)
182
182
  <span class="ruby-identifier">line</span><span class="ruby-operator">=~</span><span class="ruby-regexp re">/\((.+)\)/</span>
183
183
  <span class="ruby-ivar">@type</span> = <span class="ruby-value str">'IsFalse'</span>
@@ -205,7 +205,7 @@
205
205
  onclick="toggleCode('M000011-source');return false;">[Source]</a></p>
206
206
  <div class="method-source-code" id="M000011-source">
207
207
  <pre>
208
- <span class="ruby-comment cmt"># File lib/funit/assertions.rb, line 24</span>
208
+ <span class="ruby-comment cmt"># File lib/funit/assertions.rb, line 34</span>
209
209
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">isrealequal</span>(<span class="ruby-identifier">line</span>)
210
210
  <span class="ruby-identifier">line</span><span class="ruby-operator">=~</span><span class="ruby-regexp re">/\(([^,]+),(.+)\)/</span>
211
211
  <span class="ruby-ivar">@type</span> = <span class="ruby-value str">'IsRealEqual'</span>
@@ -233,7 +233,7 @@
233
233
  onclick="toggleCode('M000009-source');return false;">[Source]</a></p>
234
234
  <div class="method-source-code" id="M000009-source">
235
235
  <pre>
236
- <span class="ruby-comment cmt"># File lib/funit/assertions.rb, line 6</span>
236
+ <span class="ruby-comment cmt"># File lib/funit/assertions.rb, line 16</span>
237
237
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">istrue</span>(<span class="ruby-identifier">line</span>)
238
238
  <span class="ruby-identifier">line</span><span class="ruby-operator">=~</span><span class="ruby-regexp re">/\((.+)\)/</span>
239
239
  <span class="ruby-ivar">@type</span> = <span class="ruby-value str">'IsTrue'</span>
@@ -261,7 +261,7 @@
261
261
  onclick="toggleCode('M000014-source');return false;">[Source]</a></p>
262
262
  <div class="method-source-code" id="M000014-source">
263
263
  <pre>
264
- <span class="ruby-comment cmt"># File lib/funit/assertions.rb, line 51</span>
264
+ <span class="ruby-comment cmt"># File lib/funit/assertions.rb, line 61</span>
265
265
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">writeAssert</span>
266
266
  <span class="ruby-value str">&quot;\n! \#@type assertion\nnumAsserts = numAsserts + 1\nif (noAssertFailed) then\nif (\#@condition) then\nprint *, \&quot; *\#@type failed* in test \#@testName &amp;\n&amp;[\#{@suiteName}MT.ftk:\#{@lineNumber.to_s}]\&quot;\nprint *, \&quot; \&quot;, \#@message\nprint *, \&quot;\&quot;\nnoAssertFailed = .false.\nnumFailures = numFailures + 1\nelse\nnumAssertsTested = numAssertsTested + 1\nendif\nendif\n&quot;</span>
267
267
  <span class="ruby-keyword kw">end</span>
@@ -135,7 +135,7 @@
135
135
  onclick="toggleCode('M000025-source');return false;">[Source]</a></p>
136
136
  <div class="method-source-code" id="M000025-source">
137
137
  <pre>
138
- <span class="ruby-comment cmt"># File lib/funit/functions.rb, line 7</span>
138
+ <span class="ruby-comment cmt"># File lib/funit/functions.rb, line 17</span>
139
139
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">initialize</span>( <span class="ruby-identifier">name</span>=<span class="ruby-constant">ENV</span>[<span class="ruby-value str">'F9X'</span>] )
140
140
  <span class="ruby-identifier">errorMessage</span> = <span class="ruby-value str">&quot;\nFortran compiler environment variable 'F9X' not set:\n\nfor bourne-based shells: export F9X=lf95 (in .profile)\nfor c-based shells: setenv F9X lf95 (in .login)\nfor windows: set F9X=C:\\\\Program Files\\\\lf95 (in autoexec.bat)\n\n&quot;</span>
141
141
  <span class="ruby-identifier">raise</span>(<span class="ruby-identifier">errorMessage</span>) <span class="ruby-keyword kw">unless</span> <span class="ruby-ivar">@name</span> = <span class="ruby-identifier">name</span>
@@ -149,7 +149,7 @@
149
149
  onclick="toggleCode('M000015-source');return false;">[Source]</a></p>
150
150
  <div class="method-source-code" id="M000015-source">
151
151
  <pre>
152
- <span class="ruby-comment cmt"># File lib/funit/fortran_deps.rb, line 11</span>
152
+ <span class="ruby-comment cmt"># File lib/funit/fortran_deps.rb, line 21</span>
153
153
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">initialize</span>( <span class="ruby-identifier">searchPath</span> = <span class="ruby-node">%w[ ../lib . ]</span> )
154
154
  <span class="ruby-ivar">@parsed</span> = <span class="ruby-constant">Array</span>.<span class="ruby-identifier">new</span>
155
155
  <span class="ruby-ivar">@hash</span> = <span class="ruby-identifier">build_hash_of_modules_in_files_within</span> <span class="ruby-identifier">searchPath</span>
@@ -177,7 +177,7 @@
177
177
  onclick="toggleCode('M000018-source');return false;">[Source]</a></p>
178
178
  <div class="method-source-code" id="M000018-source">
179
179
  <pre>
180
- <span class="ruby-comment cmt"># File lib/funit/fortran_deps.rb, line 30</span>
180
+ <span class="ruby-comment cmt"># File lib/funit/fortran_deps.rb, line 40</span>
181
181
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">build_dictionary_of_modules_in</span>( <span class="ruby-identifier">files</span> )
182
182
  <span class="ruby-identifier">file_containing_module</span> = <span class="ruby-constant">Hash</span>.<span class="ruby-identifier">new</span>
183
183
  <span class="ruby-identifier">files</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">file</span><span class="ruby-operator">|</span>
@@ -204,7 +204,7 @@
204
204
  onclick="toggleCode('M000020-source');return false;">[Source]</a></p>
205
205
  <div class="method-source-code" id="M000020-source">
206
206
  <pre>
207
- <span class="ruby-comment cmt"># File lib/funit/fortran_deps.rb, line 45</span>
207
+ <span class="ruby-comment cmt"># File lib/funit/fortran_deps.rb, line 55</span>
208
208
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">build_hash_of_modules_in_files_within</span>( <span class="ruby-identifier">searchPath</span> = <span class="ruby-node">%w[../lib .]</span> )
209
209
  <span class="ruby-identifier">build_dictionary_of_modules_in</span>( <span class="ruby-identifier">fortran_files_within</span>( <span class="ruby-identifier">searchPath</span> ) )
210
210
  <span class="ruby-keyword kw">end</span>
@@ -227,7 +227,7 @@
227
227
  onclick="toggleCode('M000022-source');return false;">[Source]</a></p>
228
228
  <div class="method-source-code" id="M000022-source">
229
229
  <pre>
230
- <span class="ruby-comment cmt"># File lib/funit/fortran_deps.rb, line 73</span>
230
+ <span class="ruby-comment cmt"># File lib/funit/fortran_deps.rb, line 83</span>
231
231
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">dependencies</span>( <span class="ruby-identifier">start</span> )
232
232
  <span class="ruby-identifier">modules</span> = <span class="ruby-identifier">modules_used_in</span>( <span class="ruby-identifier">start</span> )
233
233
  <span class="ruby-ivar">@parsed</span> = <span class="ruby-ivar">@parsed</span> <span class="ruby-operator">||</span> [<span class="ruby-identifier">start</span>]
@@ -258,7 +258,7 @@
258
258
  onclick="toggleCode('M000019-source');return false;">[Source]</a></p>
259
259
  <div class="method-source-code" id="M000019-source">
260
260
  <pre>
261
- <span class="ruby-comment cmt"># File lib/funit/fortran_deps.rb, line 38</span>
261
+ <span class="ruby-comment cmt"># File lib/funit/fortran_deps.rb, line 48</span>
262
262
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">fortran_files_within</span>( <span class="ruby-identifier">search_path</span> = <span class="ruby-node">%w[ ../lib . ]</span> )
263
263
  <span class="ruby-identifier">source</span> = <span class="ruby-identifier">search_path</span>.<span class="ruby-identifier">map</span>{ <span class="ruby-operator">|</span><span class="ruby-identifier">path</span><span class="ruby-operator">|</span> <span class="ruby-constant">Dir</span>[<span class="ruby-identifier">path</span><span class="ruby-operator">+</span><span class="ruby-value str">&quot;/*.[fF]90&quot;</span>] }
264
264
  <span class="ruby-identifier">source</span>.<span class="ruby-identifier">flatten!</span>.<span class="ruby-identifier">uniq!</span>
@@ -284,7 +284,7 @@
284
284
  onclick="toggleCode('M000021-source');return false;">[Source]</a></p>
285
285
  <div class="method-source-code" id="M000021-source">
286
286
  <pre>
287
- <span class="ruby-comment cmt"># File lib/funit/fortran_deps.rb, line 49</span>
287
+ <span class="ruby-comment cmt"># File lib/funit/fortran_deps.rb, line 59</span>
288
288
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">makefile_dependency_line</span>( <span class="ruby-identifier">source</span> )
289
289
  <span class="ruby-identifier">realSource</span> = <span class="ruby-identifier">source</span>.<span class="ruby-identifier">sub</span>(<span class="ruby-regexp re">/PHYSICS_DUMMY/</span>,<span class="ruby-value str">'PHYSICS_MODULES'</span>)<span class="ruby-comment cmt"># What's this?</span>
290
290
  <span class="ruby-identifier">sourceNoPath</span> = <span class="ruby-constant">File</span>.<span class="ruby-identifier">basename</span> <span class="ruby-identifier">source</span>
@@ -327,7 +327,7 @@
327
327
  onclick="toggleCode('M000017-source');return false;">[Source]</a></p>
328
328
  <div class="method-source-code" id="M000017-source">
329
329
  <pre>
330
- <span class="ruby-comment cmt"># File lib/funit/fortran_deps.rb, line 24</span>
330
+ <span class="ruby-comment cmt"># File lib/funit/fortran_deps.rb, line 34</span>
331
331
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">modules_defined_in</span>( <span class="ruby-identifier">file</span> )
332
332
  <span class="ruby-identifier">modules</span> = <span class="ruby-constant">IO</span>.<span class="ruby-identifier">readlines</span>( <span class="ruby-identifier">file</span> ).<span class="ruby-identifier">map</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">line</span><span class="ruby-operator">|</span>
333
333
  <span class="ruby-identifier">$1</span>.<span class="ruby-identifier">downcase</span> <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">line</span>.<span class="ruby-identifier">match</span>( <span class="ruby-regexp re">/^\s*module\s+(\w+)/i</span> )
@@ -352,7 +352,7 @@
352
352
  onclick="toggleCode('M000016-source');return false;">[Source]</a></p>
353
353
  <div class="method-source-code" id="M000016-source">
354
354
  <pre>
355
- <span class="ruby-comment cmt"># File lib/funit/fortran_deps.rb, line 18</span>
355
+ <span class="ruby-comment cmt"># File lib/funit/fortran_deps.rb, line 28</span>
356
356
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">modules_used_in</span>( <span class="ruby-identifier">file</span> )
357
357
  <span class="ruby-identifier">modules</span> = <span class="ruby-constant">IO</span>.<span class="ruby-identifier">readlines</span>( <span class="ruby-identifier">file</span> ).<span class="ruby-identifier">map</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">line</span><span class="ruby-operator">|</span>
358
358
  <span class="ruby-identifier">$1</span>.<span class="ruby-identifier">downcase</span> <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">line</span>.<span class="ruby-identifier">match</span>( <span class="ruby-regexp re">/^\s*use\s+(\w+)/i</span> )
@@ -377,12 +377,12 @@
377
377
  onclick="toggleCode('M000024-source');return false;">[Source]</a></p>
378
378
  <div class="method-source-code" id="M000024-source">
379
379
  <pre>
380
- <span class="ruby-comment cmt"># File lib/funit/fortran_deps.rb, line 96</span>
380
+ <span class="ruby-comment cmt"># File lib/funit/fortran_deps.rb, line 106</span>
381
381
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">required_source_files</span>( <span class="ruby-identifier">head_f90</span> )
382
382
  <span class="ruby-ivar">@parsed</span>.<span class="ruby-identifier">clear</span>
383
383
  <span class="ruby-identifier">source_file_dependencies</span>( <span class="ruby-identifier">head_f90</span> )
384
384
  <span class="ruby-identifier">sources</span> = <span class="ruby-constant">Array</span>.<span class="ruby-identifier">new</span>
385
- <span class="ruby-keyword kw">while</span> <span class="ruby-operator">!</span><span class="ruby-ivar">@file_dependencies</span>.<span class="ruby-identifier">empty?</span> <span class="ruby-keyword kw">do</span>
385
+ <span class="ruby-keyword kw">while</span> <span class="ruby-operator">!</span> <span class="ruby-ivar">@file_dependencies</span>.<span class="ruby-identifier">empty?</span> <span class="ruby-keyword kw">do</span>
386
386
  <span class="ruby-identifier">no_dependents_pair</span> = <span class="ruby-ivar">@file_dependencies</span>.<span class="ruby-identifier">detect</span>{ <span class="ruby-operator">|</span><span class="ruby-identifier">h</span>,<span class="ruby-identifier">d</span><span class="ruby-operator">|</span> <span class="ruby-identifier">d</span> <span class="ruby-operator">==</span> [] }
387
387
  <span class="ruby-identifier">no_dependents</span> = <span class="ruby-identifier">no_dependents_pair</span>.<span class="ruby-identifier">first</span>
388
388
  <span class="ruby-identifier">sources</span>.<span class="ruby-identifier">push</span> <span class="ruby-identifier">no_dependents</span>
@@ -410,7 +410,7 @@
410
410
  onclick="toggleCode('M000023-source');return false;">[Source]</a></p>
411
411
  <div class="method-source-code" id="M000023-source">
412
412
  <pre>
413
- <span class="ruby-comment cmt"># File lib/funit/fortran_deps.rb, line 85</span>
413
+ <span class="ruby-comment cmt"># File lib/funit/fortran_deps.rb, line 95</span>
414
414
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">source_file_dependencies</span>( <span class="ruby-identifier">head_f90</span> )
415
415
  <span class="ruby-identifier">modules_head_uses</span> = <span class="ruby-identifier">modules_used_in</span>( <span class="ruby-identifier">head_f90</span> )
416
416
  <span class="ruby-identifier">required_f90s</span> = <span class="ruby-identifier">modules_head_uses</span>.<span class="ruby-identifier">map</span>{ <span class="ruby-operator">|</span><span class="ruby-identifier">mod</span><span class="ruby-operator">|</span> <span class="ruby-ivar">@hash</span>[<span class="ruby-identifier">mod</span>] }.<span class="ruby-identifier">compact</span>
@@ -136,7 +136,7 @@
136
136
  onclick="toggleCode('M000026-source');return false;">[Source]</a></p>
137
137
  <div class="method-source-code" id="M000026-source">
138
138
  <pre>
139
- <span class="ruby-comment cmt"># File lib/funit/test_suite.rb, line 9</span>
139
+ <span class="ruby-comment cmt"># File lib/funit/test_suite.rb, line 19</span>
140
140
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">initialize</span> <span class="ruby-identifier">suiteName</span>
141
141
  <span class="ruby-ivar">@lineNumber</span> = <span class="ruby-value str">'blank'</span>
142
142
  <span class="ruby-ivar">@suiteName</span> = <span class="ruby-identifier">suiteName</span>
@@ -169,7 +169,7 @@
169
169
  onclick="toggleCode('M000032-source');return false;">[Source]</a></p>
170
170
  <div class="method-source-code" id="M000032-source">
171
171
  <pre>
172
- <span class="ruby-comment cmt"># File lib/funit/test_suite.rb, line 109</span>
172
+ <span class="ruby-comment cmt"># File lib/funit/test_suite.rb, line 119</span>
173
173
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">aTest</span> <span class="ruby-identifier">testName</span>, <span class="ruby-identifier">ftk</span>
174
174
  <span class="ruby-ivar">@testName</span> = <span class="ruby-identifier">testName</span>
175
175
  <span class="ruby-ivar">@tests</span>.<span class="ruby-identifier">push</span> <span class="ruby-identifier">testName</span>
@@ -215,7 +215,7 @@
215
215
  onclick="toggleCode('M000029-source');return false;">[Source]</a></p>
216
216
  <div class="method-source-code" id="M000029-source">
217
217
  <pre>
218
- <span class="ruby-comment cmt"># File lib/funit/test_suite.rb, line 92</span>
218
+ <span class="ruby-comment cmt"># File lib/funit/test_suite.rb, line 102</span>
219
219
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">addtoSetup</span> <span class="ruby-identifier">ftk</span>
220
220
  <span class="ruby-keyword kw">while</span> (<span class="ruby-identifier">line</span> = <span class="ruby-identifier">ftk</span>.<span class="ruby-identifier">shift</span>) <span class="ruby-operator">&amp;&amp;</span> <span class="ruby-identifier">line</span> <span class="ruby-operator">!~</span> <span class="ruby-regexp re">/endSetup/i</span>
221
221
  <span class="ruby-ivar">@setup</span>.<span class="ruby-identifier">push</span> <span class="ruby-identifier">line</span>
@@ -240,7 +240,7 @@
240
240
  onclick="toggleCode('M000030-source');return false;">[Source]</a></p>
241
241
  <div class="method-source-code" id="M000030-source">
242
242
  <pre>
243
- <span class="ruby-comment cmt"># File lib/funit/test_suite.rb, line 98</span>
243
+ <span class="ruby-comment cmt"># File lib/funit/test_suite.rb, line 108</span>
244
244
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">addtoTeardown</span> <span class="ruby-identifier">ftk</span>
245
245
  <span class="ruby-keyword kw">while</span> (<span class="ruby-identifier">line</span> = <span class="ruby-identifier">ftk</span>.<span class="ruby-identifier">shift</span>) <span class="ruby-operator">&amp;&amp;</span> <span class="ruby-identifier">line</span> <span class="ruby-operator">!~</span> <span class="ruby-regexp re">/endTeardown/i</span>
246
246
  <span class="ruby-ivar">@teardown</span>.<span class="ruby-identifier">push</span> <span class="ruby-identifier">line</span>
@@ -265,7 +265,7 @@
265
265
  onclick="toggleCode('M000033-source');return false;">[Source]</a></p>
266
266
  <div class="method-source-code" id="M000033-source">
267
267
  <pre>
268
- <span class="ruby-comment cmt"># File lib/funit/test_suite.rb, line 136</span>
268
+ <span class="ruby-comment cmt"># File lib/funit/test_suite.rb, line 146</span>
269
269
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">close</span>
270
270
  <span class="ruby-identifier">puts</span> <span class="ruby-value str">&quot;\n subroutine Setup&quot;</span>
271
271
  <span class="ruby-identifier">puts</span> <span class="ruby-ivar">@setup</span>
@@ -307,7 +307,7 @@
307
307
  onclick="toggleCode('M000028-source');return false;">[Source]</a></p>
308
308
  <div class="method-source-code" id="M000028-source">
309
309
  <pre>
310
- <span class="ruby-comment cmt"># File lib/funit/test_suite.rb, line 49</span>
310
+ <span class="ruby-comment cmt"># File lib/funit/test_suite.rb, line 59</span>
311
311
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">expand</span>
312
312
 
313
313
  <span class="ruby-identifier">ftkFile</span> = <span class="ruby-ivar">@suiteName</span><span class="ruby-operator">+</span><span class="ruby-value str">&quot;MT.ftk&quot;</span>
@@ -369,7 +369,7 @@
369
369
  onclick="toggleCode('M000031-source');return false;">[Source]</a></p>
370
370
  <div class="method-source-code" id="M000031-source">
371
371
  <pre>
372
- <span class="ruby-comment cmt"># File lib/funit/test_suite.rb, line 104</span>
372
+ <span class="ruby-comment cmt"># File lib/funit/test_suite.rb, line 114</span>
373
373
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">ignoreTest</span> <span class="ruby-identifier">testName</span>, <span class="ruby-identifier">ftk</span>
374
374
  <span class="ruby-identifier">warning</span>(<span class="ruby-node">&quot;Ignoring test: #{testName}&quot;</span>, <span class="ruby-ivar">@suiteName</span>)
375
375
  <span class="ruby-identifier">line</span> = <span class="ruby-identifier">ftk</span>.<span class="ruby-identifier">shift</span> <span class="ruby-keyword kw">while</span> <span class="ruby-identifier">line</span> <span class="ruby-operator">!~</span> <span class="ruby-regexp re">/endTest/i</span>
@@ -393,7 +393,7 @@
393
393
  onclick="toggleCode('M000027-source');return false;">[Source]</a></p>
394
394
  <div class="method-source-code" id="M000027-source">
395
395
  <pre>
396
- <span class="ruby-comment cmt"># File lib/funit/test_suite.rb, line 21</span>
396
+ <span class="ruby-comment cmt"># File lib/funit/test_suite.rb, line 31</span>
397
397
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">topWrapper</span>
398
398
  <span class="ruby-identifier">puts</span> <span class="ruby-value str">&quot;! \#{@suiteName}MT.f90 - a Fortran mobility test suite for \#{@suiteName}.f90\n!\n! [dynamically generated from \#{@suiteName}MT.ftk\n! by \#{File.basename $0} Ruby script \#{Time.now}]\n\nmodule \#{@suiteName}MT\n\nuse \#{@suiteName}\n\nimplicit none\n\nprivate\n\npublic :: MT\#{@suiteName}\n\nlogical :: noAssertFailed\n\ninteger :: numTests = 0\ninteger :: numAsserts = 0\ninteger :: numAssertsTested = 0\ninteger :: numFailures = 0\n\n&quot;</span>
399
399
  <span class="ruby-keyword kw">end</span>
@@ -88,6 +88,12 @@
88
88
 
89
89
  <div id="contextContent">
90
90
 
91
+ <div id="description">
92
+ <p>
93
+ Create test suite wrapper code
94
+ </p>
95
+
96
+ </div>
91
97
 
92
98
 
93
99
  </div>
@@ -155,7 +161,7 @@ Class <a href="Funit/TestSuite.html" class="link">Funit::TestSuite</a><br />
155
161
  onclick="toggleCode('M000008-source');return false;">[Source]</a></p>
156
162
  <div class="method-source-code" id="M000008-source">
157
163
  <pre>
158
- <span class="ruby-comment cmt"># File lib/funit/functions.rb, line 111</span>
164
+ <span class="ruby-comment cmt"># File lib/funit/functions.rb, line 121</span>
159
165
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">compileTests</span> <span class="ruby-identifier">testSuites</span>
160
166
  <span class="ruby-identifier">puts</span> <span class="ruby-value str">&quot;computing dependencies&quot;</span>
161
167
  <span class="ruby-identifier">dependencies</span> = <span class="ruby-constant">Depend</span>.<span class="ruby-identifier">new</span>([<span class="ruby-value str">'.'</span>, <span class="ruby-value str">'../LibF90'</span>, <span class="ruby-value str">'../PHYSICS_DEPS'</span>])
@@ -185,7 +191,7 @@ Class <a href="Funit/TestSuite.html" class="link">Funit::TestSuite</a><br />
185
191
  onclick="toggleCode('M000003-source');return false;">[Source]</a></p>
186
192
  <div class="method-source-code" id="M000003-source">
187
193
  <pre>
188
- <span class="ruby-comment cmt"># File lib/funit/functions.rb, line 30</span>
194
+ <span class="ruby-comment cmt"># File lib/funit/functions.rb, line 40</span>
189
195
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">ftkExists?</span>(<span class="ruby-identifier">moduleName</span>)
190
196
  <span class="ruby-constant">File</span>.<span class="ruby-identifier">exists?</span> <span class="ruby-identifier">moduleName</span><span class="ruby-operator">+</span><span class="ruby-value str">&quot;MT.ftk&quot;</span>
191
197
  <span class="ruby-keyword kw">end</span>
@@ -208,7 +214,7 @@ Class <a href="Funit/TestSuite.html" class="link">Funit::TestSuite</a><br />
208
214
  onclick="toggleCode('M000004-source');return false;">[Source]</a></p>
209
215
  <div class="method-source-code" id="M000004-source">
210
216
  <pre>
211
- <span class="ruby-comment cmt"># File lib/funit/functions.rb, line 34</span>
217
+ <span class="ruby-comment cmt"># File lib/funit/functions.rb, line 44</span>
212
218
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">parseCommandLine</span>
213
219
 
214
220
  <span class="ruby-identifier">moduleNames</span> = <span class="ruby-identifier">requestedModules</span>(<span class="ruby-constant">ARGV</span>)
@@ -244,7 +250,7 @@ Class <a href="Funit/TestSuite.html" class="link">Funit::TestSuite</a><br />
244
250
  onclick="toggleCode('M000002-source');return false;">[Source]</a></p>
245
251
  <div class="method-source-code" id="M000002-source">
246
252
  <pre>
247
- <span class="ruby-comment cmt"># File lib/funit/functions.rb, line 23</span>
253
+ <span class="ruby-comment cmt"># File lib/funit/functions.rb, line 33</span>
248
254
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">requestedModules</span>(<span class="ruby-identifier">moduleNames</span>)
249
255
  <span class="ruby-keyword kw">if</span> (<span class="ruby-identifier">moduleNames</span>.<span class="ruby-identifier">empty?</span>)
250
256
  <span class="ruby-identifier">moduleNames</span> = <span class="ruby-constant">Dir</span>[<span class="ruby-value str">&quot;*MT.ftk&quot;</span>].<span class="ruby-identifier">each</span>{ <span class="ruby-operator">|</span><span class="ruby-identifier">mod</span><span class="ruby-operator">|</span> <span class="ruby-identifier">mod</span>.<span class="ruby-identifier">chomp!</span> <span class="ruby-value str">&quot;MT.ftk&quot;</span> }
@@ -270,7 +276,7 @@ Class <a href="Funit/TestSuite.html" class="link">Funit::TestSuite</a><br />
270
276
  onclick="toggleCode('M000001-source');return false;">[Source]</a></p>
271
277
  <div class="method-source-code" id="M000001-source">
272
278
  <pre>
273
- <span class="ruby-comment cmt"># File lib/funit.rb, line 7</span>
279
+ <span class="ruby-comment cmt"># File lib/funit.rb, line 18</span>
274
280
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">runAllFtks</span>
275
281
  <span class="ruby-constant">Compiler</span>.<span class="ruby-identifier">new</span> <span class="ruby-comment cmt"># a test for compiler env set (remove this later)</span>
276
282
  <span class="ruby-identifier">writeTestRunner</span>(<span class="ruby-identifier">testSuites</span> = <span class="ruby-identifier">parseCommandLine</span>)
@@ -303,7 +309,7 @@ Class <a href="Funit/TestSuite.html" class="link">Funit::TestSuite</a><br />
303
309
  onclick="toggleCode('M000006-source');return false;">[Source]</a></p>
304
310
  <div class="method-source-code" id="M000006-source">
305
311
  <pre>
306
- <span class="ruby-comment cmt"># File lib/funit/functions.rb, line 103</span>
312
+ <span class="ruby-comment cmt"># File lib/funit/functions.rb, line 113</span>
307
313
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">syntaxError</span>( <span class="ruby-identifier">message</span>, <span class="ruby-identifier">testSuite</span> )
308
314
  <span class="ruby-identifier">raise</span> <span class="ruby-node">&quot;\n *Error: #{message} [#{testSuite}MT.ftk:#$.]\n\n&quot;</span>
309
315
  <span class="ruby-keyword kw">end</span>
@@ -326,7 +332,7 @@ Class <a href="Funit/TestSuite.html" class="link">Funit::TestSuite</a><br />
326
332
  onclick="toggleCode('M000007-source');return false;">[Source]</a></p>
327
333
  <div class="method-source-code" id="M000007-source">
328
334
  <pre>
329
- <span class="ruby-comment cmt"># File lib/funit/functions.rb, line 107</span>
335
+ <span class="ruby-comment cmt"># File lib/funit/functions.rb, line 117</span>
330
336
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">warning</span>( <span class="ruby-identifier">message</span>, <span class="ruby-identifier">testSuite</span> )
331
337
  <span class="ruby-identifier">$stderr</span>.<span class="ruby-identifier">puts</span> <span class="ruby-node">&quot;\n *Warning: #{message} [#{testSuite}MT.ftk:#$.]&quot;</span>
332
338
  <span class="ruby-keyword kw">end</span>
@@ -349,7 +355,7 @@ Class <a href="Funit/TestSuite.html" class="link">Funit::TestSuite</a><br />
349
355
  onclick="toggleCode('M000005-source');return false;">[Source]</a></p>
350
356
  <div class="method-source-code" id="M000005-source">
351
357
  <pre>
352
- <span class="ruby-comment cmt"># File lib/funit/functions.rb, line 58</span>
358
+ <span class="ruby-comment cmt"># File lib/funit/functions.rb, line 68</span>
353
359
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">writeTestRunner</span> <span class="ruby-identifier">testSuites</span>
354
360
 
355
361
  <span class="ruby-constant">File</span>.<span class="ruby-identifier">delete</span>(<span class="ruby-value str">&quot;TestRunner.f90&quot;</span>) <span class="ruby-keyword kw">if</span> <span class="ruby-constant">File</span>.<span class="ruby-identifier">exists?</span>(<span class="ruby-value str">&quot;TestRunner.f90&quot;</span>)
@@ -1 +1 @@
1
- Sun Apr 09 01:04:11 EDT 2006
1
+ Sat Apr 15 10:41:36 EDT 2006