KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > jodd > util > TestIntHashMap


1 package jodd.util;
2
3 import junit.framework.TestCase;
4
5 public class TestIntHashMap extends TestCase {
6
7     public void testAll() {
8         IntHashMap ihm = new IntHashMap();
9
10         for (int i = 0; i < 10000; i++) {
11             ihm.put(i, new Integer(i));
12         }
13
14         for (int i = 0; i < 10000; i++) {
15             assertEquals(((Integer)ihm.get(i)).intValue(), i);
16         }
17     }
18
19 }
20
Popular Tags