[tpm] Follow-up on Feb 2012 Testing Talk

Olaf Alders olaf at vilerichard.com
Sat Mar 3 19:17:08 PST 2012

On 2012-03-03, at 10:13 AM, Rob Janes wrote:

> ## this tests the useability of the package
>   use_ok('Compress::Bzip2');
> };

I've got use_ok() and require_ok() all over a lot of my tests, but I recently moved away from that to new_ok() after finding out that it exists.  Also, there is some discussion as to the usefulness of require_ok(), because of subtle problems it can introduce.  Here's a helpful comment from Ovid about avoiding use_ok() and require_ok():


Also, I should note that the entire blog post is well worth reading.  This is where I was made aware of new_ok().


Olaf Alders
olaf at vilerichard.com

http://vilerichard.com -- folk rock

More information about the toronto-pm mailing list