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

Re^3: Testing test function

by choroba (Abbot)
on Sep 26, 2013 at 11:32 UTC ( #1055821=note: print w/ replies, xml ) Need Help??


in reply to Re^2: Testing test function
in thread Testing test function

Untested: What about

ok(! eval { test_foo(a=>2) ; 1}, 'test_foo() should fail for a=2'); is($@, 'invalid argument', 'expected error');
لսႽ ᥲᥒ⚪⟊Ⴙᘓᖇ Ꮅᘓᖇ⎱ Ⴙᥲ𝇋ƙᘓᖇ


Comment on Re^3: Testing test function
Download Code
Re^4: Testing test function
by sedusedan (Monk) on Sep 27, 2013 at 06:18 UTC
    I'm afraid that wouldn't work, because test_foo() emits TAP as well as uses the same Test::Builder instance (since it uses Test::More also) and will interfere with the test script.

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (11)
As of 2014-10-20 22:51 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    For retirement, I am banking on:










    Results (92 votes), past polls