Monks, I seek widom about testing.

Let's say I have an object-oriented distribution set up with a "modules" directory that has all the objects I want, and a /t directory with a bunch of tests.

I would like some way to check for object methods that don't have any tests. Does anything like this "test suggestor" already exist? Seems like a useful thing to be able to do. (Notice: this is just testing the object->methods(), not every single sub.)

If not, any tips on best practices on test coverage, other than "go by the gut" for this type of situation (object methods), or just testing in general?

Another idea I had was to have the .t testing files in the same directory as the .pm object files, and then at least I could see which .pm files didn't have any tests with a visual comparison. But that doesn't seem real robust ;)


In reply to Test suggestor? by tphyahoo

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.