I&#39;d actually recommend that we worry about documenting the tests after documenting the classes they test for several reasons. <div><br></div><div> - Tests are a form of documentation already. When I am looking for ways to use a class, and the class comment is insufficient, I&#39;ll often look at whatever tests are available.</div>
<div><br></div><div> - I would rather focus on the core classes that one needs to use all the time first, and work our way out from there.</div><div><br></div><div> - The way you use the tests, for most folks anyway, is to use the test runner. While I can recall having run the tests without it once, I&#39;d call that a use case for intermediate users. We still have a big fat question mark button in classes beginners will need to use, which leads them to a box that says &quot;class has no comment&quot; and I think we should deal with that *first.*</div>
<div><br></div><div>Then again, this is just how Casey&#39;s internal triage works. I am known for punting things when I see something that brains me as more important. Your spiritual mileage may of course vary!</div><div>
<br></div><div>Anyhow, it would be lovely if other folks interested might sanity check this expression as successfully excluding the tests:</div><div><br></div><div><div>(Smalltalk allClasses reject: [ :class | </div><div>
<span class="Apple-tab-span" style="white-space:pre">        </span>class inheritsFrom: TestCase ])</div><div><br></div><div class="gmail_quote">On Sun, May 2, 2010 at 12:39 PM, Michael Haupt <span dir="ltr">&lt;<a href="mailto:mhaupt@gmail.com">mhaupt@gmail.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">Hi Hannes,<br>
<div class="im"><br>
On Sun, May 2, 2010 at 9:32 PM, Hannes Hirzel &lt;<a href="mailto:hannes.hirzel@gmail.com">hannes.hirzel@gmail.com</a>&gt; wrote:<br>
&gt;&gt; So, of 2033 classes in the image, 814 have no class comment *at all*.<br>
&gt;&gt; That&#39;s 40 %, and *that* is a shame.<br>
&gt;<br>
&gt; Or put it otherwise 60% have a comment. A good point to start .....  :-)<br>
<br>
</div>I&#39;m glad to see someone is accepting the optimist hat. :-)<br>
<div class="im"><br>
&gt; The test classes are there to test the corresponding class. I think we<br>
&gt; can safely say they do not need a comment at this time. How can we<br>
&gt; exclude them from the metrics?<br>
<br>
</div>I&#39;d rather not do that - test classes may have certain characteristics<br>
in what they target, and how. It may be *very* interesting to know<br>
details about these things.<br>
<div class="im"><br>
&gt;&gt; A dictionary is not sorted by default. Or is it?<br>
&gt;<br>
&gt; So I wonder, where is the Collection with keys and values where the<br>
&gt; keys are sorted?<br>
<br>
</div>I&#39;m afraid I don&#39;t understand - Dictionary uses hashing internally.<br>
There is no sorted collection of keys in there. In case you mean to<br>
ask whether there is any Collection that does this, I&#39;m afraid there<br>
is none (but that&#39;s me talking).<br>
<br>
Best,<br>
<font color="#888888"><br>
Michael<br>
<br>
</font></blockquote></div><br><br clear="all"><br>-- <br>Casey Ransberger<br>
</div>