Java News from Sunday, December 14, 2003

Ivan Moore has released Jester 1.3.0, an interesting unit test tester tool, sadly hobbled by CLASSPATH problems, a poor user interface, abysmal error reporting, and an inability to distinguish comments from statements. The basic idea of Jester is that it mutates your source code, for instance by changing an == to a !=, runs all the tests, and sees if any of them report a failure. If none of them do, then the line of code tested is either unnecessary or untested. The results of a Jester run are often eye opening. It's an extremely valuable tool, if you can actually get it to work.

Unfortunately, Jester is mind-numbingly difficult to configure. First you have to make a copy of your source files, because Jester isn't smart enough to make its own copies before mutating them. This means you also need to make sure any paths are adjusted to the new location of the source files. You can't just copy your existing source tree and build system to a new directory because Jester insists thst the source code has to be placed in the same directories as the compiled .class files. Then the CLASSPATH needs to be set up just so. It must be set through an environment variable, not via -classpath or the ext directory. And even then the TestTester fails more often than not with no indication to the user of why the program could run. A typical message is "Sun Dec 14 08:09:11 EST 2003 running command 'java jester.TestRunnerImpl nu.xom.tests.XOMTests' resulted in '[..................FAILED]'". Yes, I know it failed. Would it be too much to ask that Jester tell me why it failed? Could it not find the test class? Was some other class missing from the CLASSPATH? Was the source code in the wrong place? What was the exception? What was the stack trace? Anything at all that would help me debug the problem?