* Test the decoding of a GracefulDisconnect with an empty delay
*/
@Test
public void testDecodeGracefulDisconnectDelayEmpty()
{
Asn1Decoder decoder = new GracefulDisconnectDecoder();
ByteBuffer bb = ByteBuffer.allocate( 0x0b );
bb.put( new byte[]
{ 0x30, 0x02, // GracefulDisconnect ::= SEQUENCE {
( byte ) 0x80, 0x00 // delay INTEGER (0..86400) DEFAULT 0
} );
bb.flip();
GracefulDisconnectContainer container = new GracefulDisconnectContainer();
try
{
decoder.decode( bb, container );
}
catch ( DecoderException de )
{
assertTrue( true );
return;