Marcin Floryan wrote:
Hi!
I've been contributing to JOSM a couple of years ago and now found some
more time to work on the project.
I was thinking of looking into unit tests a little bit and extend the
coverage. Are there any guidelines around unit testing, what's the
general approach? Do people feel adding more test coverage will be
valuable for the project?
Yes, more tests would be good. Jiri has a Hudson/Jenkins job to check
the tests regularly. (Not sure it is still running.) If you detect any
bugs, let us know.
Generally our user base is big enough to find serious problems in "hot"
code, but complicated things like JoinArea, Conflict handling / Merge
Layer would benefit from tests.
For validator: If there are false positives, we will get bug reports
very soon, but if a validation test is turned off by accident, it would
be good to have a unit test raise an alarm.
I also added HTML reports for Junit to the build (as an optional task as
it may require some dependencies for ant) but since my old SVN password
doesn't seem to work, I'm attaching it as a patch here.
Applied it in [3829].
Finally, I've played with code coverage a little bit and have managed to
generate a sample coverage report:
http://mfloryan.statnet.pl/josm-test-coverage/
I don't think that coverage is important, but I would concentrate on the
classes that would benefit the most from unit testing.
Sebastian
_______________________________________________
josm-dev mailing list
[email protected]
http://lists.openstreetmap.org/listinfo/josm-dev