String decoded = Strings.dumpBytes( stream.array() );
stream.flip();
// Allocate a EncKdcRepPart Container
EncKdcRepPartContainer encKdcRepPartContainer = new EncKdcRepPartContainer( stream );
// Decode the EncKdcRepPart PDU
try
{
decoder.decode( stream, encKdcRepPartContainer );
}
catch ( Exception e )
{
e.printStackTrace();
fail();
}
EncKdcRepPart encKdcRepPart = encKdcRepPartContainer.getEncKdcRepPart();
int computedLen = encKdcRepPart.computeLength();
assertEquals( streamLen, computedLen );