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 ValuedEnumTest.java
Date Sun, 13 Oct 2002 18:42:06 GMT
sullis      2002/10/13 11:42:06

  Modified:    lang/src/test/org/apache/commons/lang/enum
                        ValuedEnumTest.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/ValuedEnumTest.java
  
  Index: ValuedEnumTest.java
  ===================================================================
  RCS file: /home/cvs/jakarta-commons/lang/src/test/org/apache/commons/lang/enum/ValuedEnumTest.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- ValuedEnumTest.java	11 Aug 2002 23:17:54 -0000	1.1
  +++ ValuedEnumTest.java	13 Oct 2002 18:42:06 -0000	1.2
  @@ -120,6 +120,12 @@
   
       public void testList() {
           List list = ValuedColorEnum.getEnumList();
  +        
  +        assertNotNull(list);
  +        
  +        assertEquals( list.size(),
  +        			 ValuedColorEnum.getEnumMap().keySet().size());
  +        
           Iterator it = list.iterator();
           assertSame(ValuedColorEnum.RED, it.next());
           assertSame(ValuedColorEnum.GREEN, it.next());
  @@ -128,6 +134,12 @@
   
       public void testMap() {
           Map map = ValuedColorEnum.getEnumMap();
  +        
  +        assertNotNull(map);
  +        
  +        assertEquals( map.keySet().size(),
  +        			 ValuedColorEnum.getEnumList().size());
  +        			 
           assertTrue(map.containsValue(ValuedColorEnum.RED));
           assertTrue(map.containsValue(ValuedColorEnum.GREEN));
           assertTrue(map.containsValue(ValuedColorEnum.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