Beefy Boxes and Bandwidth Generously Provided by pair Networks
Do you know where your variables are?
 
PerlMonks  

Re^2: Testing my tests

by choroba (Cardinal)
on Feb 26, 2017 at 16:09 UTC ( [id://1182883]=note: print w/replies, xml ) Need Help??


in reply to Re: Testing my tests
in thread Testing my tests (mutation testing)

Boolean conditions are handled by Devel::Cover , it tells you whether you tested the TRUE and FALSE branches of them.

($q=q:Sq=~/;[c](.)(.)/;chr(-||-|5+lengthSq)`"S|oS2"`map{chr |+ord }map{substrSq`S_+|`|}3E|-|`7**2-3:)=~y+S|`+$1,++print+eval$q,q,a,

Replies are listed 'Best First'.
Re^3: Testing my tests
by stevieb (Canon) on Feb 26, 2017 at 16:14 UTC

    Right, but I think what he's asking about is whether the return values themselves have been tested against directly. I just put in the if statements to show that to do what he wants, some serious thought would have to be put into the introspection to ensure that if you could prove that an assertion has been made, it would also have to be confirmed which return path the return came out of.

      "Right, but I think what he's asking about is whether the return values themselves have been tested against directly."

      Don't assume, ASK! But consider that if you test your interfaces then those return values WILL BE IN THE TEST. That's what a test does -- it checks that the return value is what you expected. Coverage shows you which branches have been executed by those tests and which have not.

      Testing is simple. People make it complicated.

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others about the Monastery: (5)
As of 2024-03-28 22:54 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found