On Thu, 2007-02-15 at 11:12 +0900, Ryan Davis wrote:
> On Feb 14, 2007, at 6:12 AM, Daniel Schierbeck wrote:
> 
> > On Wed, 2007-02-14 at 07:43 +0900, Ryan Davis wrote:
> >> heckle version 1.2.0 has been released!
> >>
> >>    http://www.rubyforge.org/projects/seattlerb
> >>    by Ryan Davis and Kevin Clark
> >>
> >> Heckle is a mutation tester. It modifies your code and runs your
> >> tests to make sure they fail. The idea is that if code can be changed
> >> and your tests don't notice, either that code isn't being covered or
> >> it doesn't do anything.
> >
> > Hey Ryan, great stuff! I've just got one question: I'm adding some
> > methods to Integer, String, etc., and I'm having trouble heckling my
> > tests - when I do `heckle Integer' for example, it runs though *each*
> > method on Integer, not just the ones defined by myself. Is there a way
> > to restrict the scope of the heckling?
> 
> Other than the single method heckling that Jan points out, there is  
> little I can offer. Because of the way that ruby and ParseTree work,  
> heckle can't really tell what is extending a class and what isn't.  
> That is pretty much just how it works internally. We do a good job of  
> not bothering with the core methods, but YAML and a bunch of other  
> stuff get layered on through rubygems and such.
> 
> I'd suggest either the single method heckling route or moving your  
> code to a module and heckling that. We can extend heckle's single  
> method arg in the future to be more convenient. I want a persistent  
> heckle mode that knows what failed last time.

How about, when heckle first runs the tests, recording what methods were
called, and then restricting the heckling to that? RCov should be able
to point out if a method isn't being covered at all, so heckle really
just needs to test the quality of the tests and implementation. 


Cheers,
Daniel