directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From a..@apache.org
Subject svn commit: rev 21099 - in incubator/directory/snickers: branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber trunk/codec-stateful/src/java/org/apache/commons/codec/stateful
Date Fri, 11 Jun 2004 14:15:34 GMT
Author: adc
Date: Fri Jun 11 07:15:33 2004
New Revision: 21099

Added:
   incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/ConstructedTLVTest.java
      - copied, changed from rev 21091, incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/ConstructedTLVTests.java
   incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/MultiByteLengthTest.java
      - copied, changed from rev 21091, incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/MultiByteLengthTests.java
   incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/MultiByteTagTest.java
      - copied, changed from rev 21091, incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/MultiByteTagTests.java
   incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/SimplePrimitiveTLVTest.java
      - copied, changed from rev 21091, incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/SimplePrimitiveTLVTests.java
   incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/SingleByteLengthTest.java
      - copied, changed from rev 21091, incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/SingleByteLengthTests.java
   incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/SingleByteTagTest.java
      - copied, changed from rev 21091, incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/SingleByteTagTests.java
Removed:
   incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/ConstructedTLVTests.java
   incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/MultiByteLengthTests.java
   incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/MultiByteTagTests.java
   incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/SimplePrimitiveTLVTests.java
   incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/SingleByteLengthTests.java
   incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/SingleByteTagTests.java
Modified:
   incubator/directory/snickers/trunk/codec-stateful/src/java/org/apache/commons/codec/stateful/AbstractStatefulDecoder.java
Log:
Renamed classes so that they would be picked up in unit tests.

Copied: incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/ConstructedTLVTest.java
(from rev 21091, incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/ConstructedTLVTests.java)
==============================================================================
--- incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/ConstructedTLVTests.java
(original)
+++ incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/ConstructedTLVTest.java
Fri Jun 11 07:15:33 2004
@@ -24,18 +24,18 @@
  * Apache Directory Project</a>
  * @version $Rev$
  */
-public class ConstructedTLVTests extends AbstractDecoderTestCase
+public class ConstructedTLVTest extends AbstractDecoderTestCase
 {
 
     /**
      * @param arg0
      */
-    public ConstructedTLVTests( String arg0 )
+    public ConstructedTLVTest( String arg0 )
     {
         super( arg0 ) ;
     }
-    
-    
+
+
     public void testConstructedDefinateTLV() throws Exception
     {
         // decode tag
@@ -45,11 +45,11 @@
         assertEquals( false, outter.isPrimitive ) ;
         assertEquals( TypeClass.APPLICATION, outter.typeClass ) ;
         assertEquals( decoder.LENGTH_STATE, decoder.getState() ) ;
-        
-        // decode length 
+
+        // decode length
         outter = decode( "00000011" ) ;
         assertEquals( decoder.TAG_STATE, decoder.getState() ) ;
-        
+
         // decode tag
         Tuple tlv = decode( "01000001" ) ;
         assertEquals( 1, tlv.id ) ;
@@ -57,12 +57,12 @@
         assertEquals( true, tlv.isPrimitive ) ;
         assertEquals( TypeClass.APPLICATION, tlv.typeClass ) ;
         assertEquals( decoder.LENGTH_STATE, decoder.getState() ) ;
-        
-        // decode length 
+
+        // decode length
         tlv = decode( "00000001" ) ;
         assertEquals( decoder.VALUE_STATE, decoder.getState() ) ;
         assertEquals( 1, tlv.length ) ;
-        
+
         // decode value
         setExpectedState( decoder.VALUE_STATE );
         tlv = decode( "01010101" ) ;
@@ -74,7 +74,7 @@
     public void testMultipleIndefinateTLV() throws Exception
     {
         // --------------------------------------------------------------------
-        
+
         // decode tag
         Tuple outter = decode( "01100001" ) ;
         assertEquals( 1, outter.id ) ;
@@ -82,15 +82,15 @@
         assertEquals( false, outter.isPrimitive ) ;
         assertEquals( TypeClass.APPLICATION, outter.typeClass ) ;
         assertEquals( decoder.LENGTH_STATE, decoder.getState() ) ;
-        
-        // decode length 
+
+        // decode length
         outter = decode( "10000000" ) ;
         assertEquals( decoder.TAG_STATE, decoder.getState() ) ;
 
-        
+
         // --------------------------------------------------------------------
 
-        
+
         // decode tag
         Tuple tlv = decode( "01000001" ) ;
         assertEquals( 1, tlv.id ) ;
@@ -98,13 +98,13 @@
         assertEquals( true, tlv.isPrimitive ) ;
         assertEquals( TypeClass.APPLICATION, tlv.typeClass ) ;
         assertEquals( decoder.LENGTH_STATE, decoder.getState() ) ;
-        
-        // decode length 
+
+        // decode length
         tlv = decode( "00000001" ) ;
         assertEquals( decoder.VALUE_STATE, decoder.getState() ) ;
         assertEquals( 1, tlv.length ) ;
         assertEquals( 0, tlvList.size() ) ;
-        
+
         // decode value
         setExpectedState( decoder.VALUE_STATE );
         tlv = decode( "01010101" ) ;
@@ -112,7 +112,7 @@
         assertEquals( 1, tlvList.size() ) ;
         assertEquals( 0x0055, 0x00ff & buffer.get( 0 ) ) ;
 
-        
+
         // --------------------------------------------------------------------
 
 
@@ -123,19 +123,19 @@
         assertEquals( true, tlv.isPrimitive ) ;
         assertEquals( TypeClass.APPLICATION, tlv.typeClass ) ;
         assertEquals( decoder.LENGTH_STATE, decoder.getState() ) ;
-        
-        // decode length 
+
+        // decode length
         tlv = decode( "00000001" ) ;
         assertEquals( decoder.VALUE_STATE, decoder.getState() ) ;
         assertEquals( 1, tlv.length ) ;
-        
+
         // decode value
         tlv = decode( "01010101" ) ;
         assertEquals( decoder.TAG_STATE, decoder.getState() ) ;
         assertEquals( 2, tlvList.size() ) ;
         assertEquals( 0x0055, 0x00ff & buffer.get( 0 ) ) ;
 
-    
+
         // --------------------------------------------------------------------
 
 
@@ -146,12 +146,12 @@
         assertEquals( true, tlv.isPrimitive ) ;
         assertEquals( TypeClass.APPLICATION, tlv.typeClass ) ;
         assertEquals( decoder.LENGTH_STATE, decoder.getState() ) ;
-        
-        // decode length 
+
+        // decode length
         tlv = decode( "00000001" ) ;
         assertEquals( decoder.VALUE_STATE, decoder.getState() ) ;
         assertEquals( 1, tlv.length ) ;
-        
+
         // decode value
         tlv = decode( "01010101" ) ;
         assertEquals( decoder.TAG_STATE, decoder.getState() ) ;
@@ -161,7 +161,7 @@
         decode( "00000000" ) ;
         setExpectedState( decoder.LENGTH_STATE );
         decode( "00000000" ) ;
-        
+
         assertEquals( 4, tlvList.size() ) ;
         assertEquals( decoder.TAG_STATE, decoder.getState() ) ;
     }
@@ -169,13 +169,13 @@
 
     public void testIllegalState() throws Exception
     {
-        try 
+        try
         {
             decode( "00000000" ) ;
             decode( "00000000" ) ;
             fail( "should throw an exception before getting here" ) ;
         }
-        catch( Throwable e ) 
+        catch( Throwable e )
         {
             assertNotNull( e ) ;
         }
@@ -185,14 +185,14 @@
     public void testIllegalStateNoMonitor() throws Exception
     {
         decoder.setDecoderMonitor( null ) ;
-        
-        try 
+
+        try
         {
             decode( "00000000" ) ;
             decode( "00000000" ) ;
             fail( "should throw an exception before getting here" ) ;
         }
-        catch( Throwable e ) 
+        catch( Throwable e )
         {
             assertNotNull( e ) ;
         }

Copied: incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/MultiByteLengthTest.java
(from rev 21091, incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/MultiByteLengthTests.java)
==============================================================================
--- incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/MultiByteLengthTests.java
(original)
+++ incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/MultiByteLengthTest.java
Fri Jun 11 07:15:33 2004
@@ -24,19 +24,19 @@
  * Apache Directory Project</a>
  * @version $Rev$
  */
-public class MultiByteLengthTests extends AbstractDecoderTestCase
+public class MultiByteLengthTest extends AbstractDecoderTestCase
 {
     /**
      * Creates a single byte lenth test case.
-     * 
+     *
      * @param name the name of this test
      */
-    public MultiByteLengthTests( String name )
+    public MultiByteLengthTest( String name )
     {
         super( name ) ;
     }
 
-    
+
     public void testLength128() throws Exception
     {
         Tuple tlv = decode( "01000001" ) ;
@@ -46,7 +46,7 @@
         assertEquals( TypeClass.APPLICATION, tlv.typeClass ) ;
         assertEquals( decoder.LENGTH_STATE, decoder.getState() ) ;
         assertEquals( 0, tlv.length ) ;
-        
+
         tlv = decode( "10000001" ) ;
         assertEquals( decoder.LENGTH_STATE, decoder.getState() ) ;
         assertEquals( 0, tlv.length ) ;
@@ -66,7 +66,7 @@
         assertEquals( TypeClass.APPLICATION, tlv.typeClass ) ;
         assertEquals( decoder.LENGTH_STATE, decoder.getState() ) ;
         assertEquals( 0, tlv.length ) ;
-        
+
         tlv = decode( "10000001" ) ;
         assertEquals( decoder.LENGTH_STATE, decoder.getState() ) ;
         assertEquals( 0, tlv.length ) ;
@@ -86,7 +86,7 @@
         assertEquals( TypeClass.APPLICATION, tlv.typeClass ) ;
         assertEquals( decoder.LENGTH_STATE, decoder.getState() ) ;
         assertEquals( 0, tlv.length ) ;
-        
+
         tlv = decode( "10000001" ) ;
         assertEquals( decoder.LENGTH_STATE, decoder.getState() ) ;
         assertEquals( 0, tlv.length ) ;
@@ -95,8 +95,8 @@
         assertEquals( decoder.VALUE_STATE, decoder.getState() ) ;
         assertEquals( 255, tlv.length ) ;
     }
-    
-    
+
+
     public void testLength32768() throws Exception
     {
         Tuple tlv = decode( "01000001" ) ;
@@ -106,7 +106,7 @@
         assertEquals( TypeClass.APPLICATION, tlv.typeClass ) ;
         assertEquals( decoder.LENGTH_STATE, decoder.getState() ) ;
         assertEquals( 0, tlv.length ) ;
-        
+
         tlv = decode( "10000010" ) ;
         assertEquals( decoder.LENGTH_STATE, decoder.getState() ) ;
         assertEquals( 0, tlv.length ) ;
@@ -119,8 +119,8 @@
         assertEquals( decoder.VALUE_STATE, decoder.getState() ) ;
         assertEquals( 32768, tlv.length ) ;
     }
-    
-    
+
+
     public void testLength65535() throws Exception
     {
         Tuple tlv = decode( "01000001" ) ;
@@ -130,7 +130,7 @@
         assertEquals( TypeClass.APPLICATION, tlv.typeClass ) ;
         assertEquals( decoder.LENGTH_STATE, decoder.getState() ) ;
         assertEquals( 0, tlv.length ) ;
-        
+
         tlv = decode( "10000010" ) ;
         assertEquals( decoder.LENGTH_STATE, decoder.getState() ) ;
         assertEquals( 0, tlv.length ) ;

Copied: incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/MultiByteTagTest.java
(from rev 21091, incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/MultiByteTagTests.java)
==============================================================================
--- incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/MultiByteTagTests.java
(original)
+++ incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/MultiByteTagTest.java
Fri Jun 11 07:15:33 2004
@@ -18,14 +18,14 @@
 
 
 /**
- * Here we test simple 1 byte tag and length values to test the decoder's 
+ * Here we test simple 1 byte tag and length values to test the decoder's
  * ability to handle these most simple tlvs.
  *
  * @author <a href="mailto:directory-dev@incubator.apache.org">
  * Apache Directory Project</a>
  * @version $Rev$
  */
-public class MultiByteTagTests extends AbstractDecoderTestCase
+public class MultiByteTagTest extends AbstractDecoderTestCase
 {
     /** precalculated left shift of 1 by 14 places */
     private static final int BIT_13 = 1 << 14 ;
@@ -37,17 +37,17 @@
     private static final int BIT_23 = 1 << 24 ;
     /** precalculated left shift of 1 by 28 places */
     private static final int BIT_27 = 1 << 28 ;
-    
+
 
     /**
      * @param arg0
      */
-    public MultiByteTagTests( String arg0 )
+    public MultiByteTagTest( String arg0 )
     {
         super( arg0 ) ;
     }
-    
-    
+
+
     public void testId31() throws Exception
     {
         Tuple tlv = decode( "00011111" + "01011111") ;
@@ -145,7 +145,7 @@
         assertEquals( decoder.LENGTH_STATE, decoder.getState() ) ;
     }
 
-    
+
     public void testIdShift21Minus1() throws Exception
     {
         Tuple tlv = decode( "01111111" + "11111111" + "11111111" + "01011111" ) ;

Copied: incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/SimplePrimitiveTLVTest.java
(from rev 21091, incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/SimplePrimitiveTLVTests.java)
==============================================================================
--- incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/SimplePrimitiveTLVTests.java
(original)
+++ incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/SimplePrimitiveTLVTest.java
Fri Jun 11 07:15:33 2004
@@ -26,18 +26,18 @@
  * Apache Directory Project</a>
  * @version $Rev$
  */
-public class SimplePrimitiveTLVTests extends AbstractDecoderTestCase
+public class SimplePrimitiveTLVTest extends AbstractDecoderTestCase
 {
 
     /**
      * @param arg0
      */
-    public SimplePrimitiveTLVTests( String arg0 )
+    public SimplePrimitiveTLVTest( String arg0 )
     {
         super( arg0 ) ;
     }
-    
-    
+
+
     public void testSingleSimpleTLV() throws Exception
     {
         // decode tag
@@ -47,12 +47,12 @@
         assertEquals( true, tlv.isPrimitive ) ;
         assertEquals( TypeClass.APPLICATION, tlv.typeClass ) ;
         assertEquals( decoder.LENGTH_STATE, decoder.getState() ) ;
-        
-        // decode length 
+
+        // decode length
         tlv = decode( "00000001" ) ;
         assertEquals( decoder.VALUE_STATE, decoder.getState() ) ;
         assertEquals( 1, tlv.length ) ;
-        
+
         // decode value
         this.setExpectedState( decoder.VALUE_STATE );
         tlv = decode( "01010101" ) ;
@@ -71,12 +71,12 @@
         assertEquals( true, tlv.isPrimitive ) ;
         assertEquals( TypeClass.APPLICATION, tlv.typeClass ) ;
         assertEquals( decoder.LENGTH_STATE, decoder.getState() ) ;
-        
-        // decode length 
+
+        // decode length
         tlv = decode( "00000001" ) ;
         assertEquals( decoder.VALUE_STATE, decoder.getState() ) ;
         assertEquals( 1, tlv.length ) ;
-        
+
         // decode value
         this.setExpectedState( decoder.VALUE_STATE );
         tlv = decode( "01010101" ) ;
@@ -84,7 +84,7 @@
         assertEquals( 1, tlvList.size() ) ;
         assertEquals( 0x0055, 0x00ff & buffer.get() ) ;
 
-    
+
         // decode tag
         tlv = decode( "01000001" ) ;
         assertEquals( 1, tlv.id ) ;
@@ -92,12 +92,12 @@
         assertEquals( true, tlv.isPrimitive ) ;
         assertEquals( TypeClass.APPLICATION, tlv.typeClass ) ;
         assertEquals( decoder.LENGTH_STATE, decoder.getState() ) ;
-        
-        // decode length 
+
+        // decode length
         tlv = decode( "00000001" ) ;
         assertEquals( decoder.VALUE_STATE, decoder.getState() ) ;
         assertEquals( 1, tlv.length ) ;
-        
+
         // decode value
         this.setExpectedState( decoder.VALUE_STATE );
         tlv = decode( "01010101" ) ;
@@ -105,7 +105,7 @@
         assertEquals( 2, tlvList.size() ) ;
         assertEquals( 0x0055, 0x00ff & buffer.get() ) ;
 
-    
+
         // decode tag
         tlv = decode( "01000001" ) ;
         assertEquals( 1, tlv.id ) ;
@@ -113,12 +113,12 @@
         assertEquals( true, tlv.isPrimitive ) ;
         assertEquals( TypeClass.APPLICATION, tlv.typeClass ) ;
         assertEquals( decoder.LENGTH_STATE, decoder.getState() ) ;
-        
-        // decode length 
+
+        // decode length
         tlv = decode( "00000001" ) ;
         assertEquals( decoder.VALUE_STATE, decoder.getState() ) ;
         assertEquals( 1, tlv.length ) ;
-        
+
         // decode value
         this.setExpectedState( decoder.VALUE_STATE );
         tlv = decode( "01010101" ) ;
@@ -137,16 +137,16 @@
         assertEquals( true, tlv.isPrimitive ) ;
         assertEquals( TypeClass.APPLICATION, tlv.typeClass ) ;
         assertEquals( decoder.LENGTH_STATE, decoder.getState() ) ;
-        
-        // decode length 
+
+        // decode length
         tlv = decode( "10000001" ) ;
         assertEquals( decoder.LENGTH_STATE, decoder.getState() ) ;
         assertEquals( 0, tlv.length ) ;
-        
+
         tlv = decode( "00000111" ) ;
         assertEquals( decoder.VALUE_STATE, decoder.getState() ) ;
         assertEquals( 7, tlv.length ) ;
-        
+
         // decode value
         this.setExpectedState( decoder.VALUE_STATE );
         tlv = decode( "01010101" + "01010101" + "01010101" + "01010101"
@@ -154,10 +154,10 @@
         assertEquals( decoder.TAG_STATE, decoder.getState() ) ;
         assertEquals( 1, tlvList.size() ) ;
         assertEquals( 7, buffer.limit() ) ;
-        
+
         ByteBuffer value = buffer.duplicate() ;
         for ( int ii = 0 ; ii < 7; ii++ )
-        {    
+        {
             assertEquals( 0x0055, 0x00ff & value.get( ii ) ) ;
         }
     }

Copied: incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/SingleByteLengthTest.java
(from rev 21091, incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/SingleByteLengthTests.java)
==============================================================================
--- incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/SingleByteLengthTests.java
(original)
+++ incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/SingleByteLengthTest.java
Fri Jun 11 07:15:33 2004
@@ -24,21 +24,21 @@
  * Apache Directory Project</a>
  * @version $Rev$
  */
-public class SingleByteLengthTests extends AbstractDecoderTestCase
+public class SingleByteLengthTest extends AbstractDecoderTestCase
 {
     /**
      * Creates a single byte lenth test case.
-     * 
+     *
      * @param name the name of this test
      */
-    public SingleByteLengthTests( String name )
+    public SingleByteLengthTest( String name )
     {
         super( name ) ;
     }
 
 
     /**
-     * This encoding's tuple should complete 
+     * This encoding's tuple should complete
      * @throws Exception
      */
     public void testLength0() throws Exception

Copied: incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/SingleByteTagTest.java
(from rev 21091, incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/SingleByteTagTests.java)
==============================================================================
--- incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/SingleByteTagTests.java
(original)
+++ incubator/directory/snickers/branches/ber-decoder/ber-codec/src/test/org/apache/snickers/ber/SingleByteTagTest.java
Fri Jun 11 07:15:33 2004
@@ -18,25 +18,25 @@
 
 
 /**
- * Here we test simple 1 byte tag and length values to test the decoder's 
+ * Here we test simple 1 byte tag and length values to test the decoder's
  * ability to handle these most simple tlvs.
  *
  * @author <a href="mailto:directory-dev@incubator.apache.org">
  * Apache Directory Project</a>
  * @version $Rev$
  */
-public class SingleByteTagTests extends AbstractDecoderTestCase
+public class SingleByteTagTest extends AbstractDecoderTestCase
 {
 
     /**
      * @param arg0
      */
-    public SingleByteTagTests( String arg0 )
+    public SingleByteTagTest( String arg0 )
     {
         super( arg0 ) ;
     }
-    
-    
+
+
     public void testAppTypeClass() throws Exception
     {
         Tuple tlv = decode( "01000001" ) ;
@@ -69,7 +69,7 @@
         assertEquals( decoder.LENGTH_STATE, decoder.getState() ) ;
     }
 
-    
+
     public void testUniTypeClass() throws Exception
     {
         Tuple tlv = decode( "01000001" ) ;
@@ -80,14 +80,14 @@
         assertEquals( decoder.LENGTH_STATE, decoder.getState() ) ;
 
     }
-    
+
     public void testIllegalStateWithUniTypeClass() throws Exception
     {
         try
         {
             Tuple tlv = decode( "00000001" ) ;
         }
-        catch( IllegalStateException e ) 
+        catch( IllegalStateException e )
         {
             assertNotNull( e ) ;
         }
@@ -421,21 +421,21 @@
         assertEquals( TypeClass.APPLICATION, tlv.typeClass ) ;
         assertEquals( decoder.LENGTH_STATE, decoder.getState() ) ;
     }
-    
-    
+
+
     public void testIdOverLimit() throws Exception
     {
         // this is the long form
         Tuple tlv = decode( "01011111" ) ;
-        
+
         assertEquals( null, tlv ) ;
         assertEquals( 0, tlvList.size() ) ;
-        
-        // state did not switch since we are still reading the long tag  
+
+        // state did not switch since we are still reading the long tag
         assertEquals( decoder.TAG_STATE, decoder.getState() ) ;
     }
 
-    
+
     public void testIsConstructed() throws Exception
     {
         Tuple tlv = decode( "01111110" ) ;

Modified: incubator/directory/snickers/trunk/codec-stateful/src/java/org/apache/commons/codec/stateful/AbstractStatefulDecoder.java
==============================================================================
--- incubator/directory/snickers/trunk/codec-stateful/src/java/org/apache/commons/codec/stateful/AbstractStatefulDecoder.java
(original)
+++ incubator/directory/snickers/trunk/codec-stateful/src/java/org/apache/commons/codec/stateful/AbstractStatefulDecoder.java
Fri Jun 11 07:15:33 2004
@@ -94,11 +94,6 @@
     {
         DecoderCallback old = this.cb ;
         this.cb = cb ;
-        
-        if ( monitor != null )
-        {
-            monitor.callbackSet( this, old, cb ) ;
-        }
     }
     
 
@@ -128,11 +123,6 @@
         if ( cb != null )
         {    
             cb.decodeOccurred( this, decoded ) ;
-        }
-        
-        if ( monitor != null )
-        {    
-            monitor.callbackOccured( this, cb, decoded ) ;
         }
     }
     

Mime
View raw message