Beefy Boxes and Bandwidth Generously Provided by pair Networks
Think about Loose Coupling
 
PerlMonks  

Re^3: RFC: How did I do writing my first test?

by tobyink (Canon)
on Sep 24, 2020 at 15:15 UTC ( #11122162=note: print w/replies, xml ) Need Help??


in reply to Re^2: RFC: How did I do writing my first test?
in thread RFC: How did I do writing my first test?

Tests can be useful as additional documentation. Type::Tiny::Manual::AllTypes explicitly links to a directory in the Type::Tiny test suite that is intended to act as in-depth documentation. It tests combinations of things you might not expect to ever see, so perhaps wouldn't see explicitly documented elsewhere, like "should a blessed arrayref pass the type constraint for negative integers?"

Certainly most of the test suite is not written with that in mind, but I do think having a test suite that is organized and provides a demonstration of every feature of the software is a worthy goal, and once that goal has been achieved then your tests will act as documentation whether you intended it that way or not.

  • Comment on Re^3: RFC: How did I do writing my first test?

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://11122162]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others wandering the Monastery: (6)
As of 2021-01-22 00:28 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Notices?