|
 |
Darren New wrote:
> It just seems to me that in most everything I do, either I have
> something impossible to mock, something unreasonable to check
> extensively by hand (and which will yield wrong results in a small
> percentage of cases), or there's output from the routines that gets
> interpreted by something else, so there's a huge number of equivalent
> results that are all "correct". (How do you unit-test automatically that
> your UI javascript does the right thing in all the browsers you care
> about?)
I'm currently trying to implement a PostScript interpretter. Do you have
*any idea* how non-trivial it is to come up with good tests which cover
all possible corner-cases? Do you have any idea how you verify what the
"correct" result is even supposed to be? (Currently I just check it
against GhostScript, but that just means my program will have the same
bus that GS has! And even that testing isn't trivial...)
So far, I'm still testing the damned parser! I haven't even got to the
part where I execute anything... :-(
(PostScript also turns out to be a highly non-trivial language. There
are so many minor details which screw things up. Like the special
handling for literal procedures encountered on stdin...)
--
http://blog.orphi.me.uk/
http://www.zazzle.com/MathematicalOrchid*
Post a reply to this message
|
 |