David Cantrell wrote:
Has anyone done any perl fuzz-testing - that is, written something that
generates valid but silly code in an attempt to find errors in the
interpreter or in a module?
It seems like a worthwhile thing to do, but I'm struggling to imagine
what it would look like, particularly for testing pure-perl modules.
Ilya used to do something like that every once in a while. IIRC he'd just
generate random strings of varying lengths and eval them until he found a
leak or a crash. I suppose you could do something similar with regular
expressions.
I wonder if you can use PPI and walk through the DOM asking it "what are all
the possible valid tokens here?", appending one at random and repeating.
You'll be wanting to do this in a jail because those Shakespeare writing
monkeys might come up with "To be or not to system 'rm -rf /'"