开发者

JUnit tests for collections

I've implemented a Radix Trie (aka Patricia Trie) in Java, and would like to thoroughly test it. It implements the Map, SortedMap and NavigableMap interfaces, which add up to a pretty large number of methods to check. =/

I figure the people who wrote li开发者_StackOverflow中文版brary classes like HashMap and TreeMap must have had a suite of JUnit tests (or something similar) to ensure they behave correctly. Does anyone know of a way to get the source code of these tests? I'd love to put this code through the same paces.


In the google collections library, there are some basic test harnesses that thoroughly test the contracts of various structures, including maps.

Here is a link to the gcode page: http://code.google.com/p/google-collections/

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜