Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl-Sensitive Sunglasses
 
PerlMonks  

Re: Testing a XS module

by chargrill (Parson)
on Aug 29, 2007 at 16:31 UTC ( #635843=note: print w/ replies, xml ) Need Help??


in reply to Testing a XS module

You're not using Test::More's tests, even though when you use it, you tell it you will (via tests => 4). I would be inclined to rewrite your tests as follows:

use Test::More tests => 4; BEGIN {use_ok('Mytest')} is( Mytest::is_even(0), 1, 'is_even says 0 is even' ); is( Mytest::is_even(1), 0, 'is_even says 1 is not even' ); is( Mytest::is_even(2), 1, 'is_even says 2 is even' );

--chargrill
s**lil*; $*=join'',sort split q**; s;.*;grr; &&s+(.(.)).+$2$1+; $; = qq-$_-;s,.*,ahc,;$,.=chop for split q,,,reverse;print for($,,$;,$*,$/)


Comment on Re: Testing a XS module
Select or Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others having an uproarious good time at the Monastery: (12)
As of 2014-07-30 11:37 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My favorite superfluous repetitious redundant duplicative phrase is:









    Results (230 votes), past polls