commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sul...@apache.org
Subject cvs commit: jakarta-commons/lang/src/test/org/apache/commons/lang/enum EnumTest.java
Date Sun, 13 Oct 2002 18:41:24 GMT
sullis      2002/10/13 11:41:24

  Modified:    lang/src/test/org/apache/commons/lang/enum EnumTest.java
  Log:
  added test code for Map keySet size and List size
  
  Revision  Changes    Path
  1.2       +13 -1     jakarta-commons/lang/src/test/org/apache/commons/lang/enum/EnumTest.java
  
  Index: EnumTest.java
  ===================================================================
  RCS file: /home/cvs/jakarta-commons/lang/src/test/org/apache/commons/lang/enum/EnumTest.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- EnumTest.java	11 Aug 2002 23:17:54 -0000	1.1
  +++ EnumTest.java	13 Oct 2002 18:41:24 -0000	1.2
  @@ -114,6 +114,12 @@
   
       public void testList() {
           List list = ColorEnum.getEnumList();
  +        
  +        assertNotNull(list);
  +        
  +        assertEquals( list.size(),
  +        				ColorEnum.getEnumMap().keySet().size());
  +        
           Iterator it = list.iterator();
           assertSame(ColorEnum.RED, it.next());
           assertSame(ColorEnum.GREEN, it.next());
  @@ -122,6 +128,12 @@
   
       public void testMap() {
           Map map = ColorEnum.getEnumMap();
  +        
  +        assertNotNull(map);
  +        
  +        assertEquals( map.keySet().size(),
  +        				ColorEnum.getEnumList().size());
  +        
           assertTrue(map.containsValue(ColorEnum.RED));
           assertTrue(map.containsValue(ColorEnum.GREEN));
           assertTrue(map.containsValue(ColorEnum.BLUE));
  
  
  

--
To unsubscribe, e-mail:   <mailto:commons-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:commons-dev-help@jakarta.apache.org>


Mime
View raw message