[TIP] Model checking Python code
matthewharrison at gmail.com
Fri Sep 4 11:24:09 PDT 2009
On Fri, Sep 4, 2009 at 11:45 AM, Mark Seaborn<mrs at mythic-beasts.com> wrote:
> If there are multiple choices to be made, the multiplying out (to give
> the Cartesian product) is done by the check runner, which is performing
> a kind of inversion of control.
> I'd be interested to hear if anyone has used this kind of technique in
> Python before, or if anyone thinks it would help solve problems
> they've encountered before.
I read your blog post this sounds interesting. In fact I gave a talk
about a related subject two years ago at pycon. I covered
cyclomatic complexity, code coverage and how they relate. The problem
is that Python currently only supports line coverage, which by itself
is not sufficient to support more advanced tools.
When you take the people who care about testing, and take the subset
that care about coverage, and take the subset that care about
path/model checking, I think that you get a really small percentage of
Any tool which wants to increase the size of these smaller subsets of
programmers is going to have to be:
* Very easy to use
* Provide some utility
I need to market, work on pycoverage.el more (which is an even smaller
subset of the above that use emacs), because I think it lies along the
path of where you want to go.
I guess my point is that there are people who find this cool, so don't give up!
What I'd like is a way to tell which of the paths I've covered from
the basis paths. (from linear algebra, once you cover the basis paths,
other paths are just linear combinations of them). (I even messed
around with the CPython eval loop trying to get more fine grained
tracing, but real life caught up with me and I moved on).
I'm interested in seeing where your project goes. Keep us posted.
0 - http://panela.blog-city.com/pycon_2008_managing_complexity_slides.htm
More information about the testing-in-python