Return-Path: Delivered-To: apmail-directory-commits-archive@www.apache.org Received: (qmail 67760 invoked from network); 23 Nov 2005 13:36:06 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 23 Nov 2005 13:36:06 -0000 Received: (qmail 68505 invoked by uid 500); 23 Nov 2005 13:35:56 -0000 Delivered-To: apmail-directory-commits-archive@directory.apache.org Received: (qmail 68438 invoked by uid 500); 23 Nov 2005 13:35:56 -0000 Mailing-List: contact commits-help@directory.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@directory.apache.org Delivered-To: mailing list commits@directory.apache.org Received: (qmail 68414 invoked by uid 99); 23 Nov 2005 13:35:55 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 23 Nov 2005 05:35:55 -0800 X-ASF-Spam-Status: No, hits=-9.4 required=10.0 tests=ALL_TRUSTED,NO_REAL_NAME X-Spam-Check-By: apache.org Received: from [209.237.227.194] (HELO minotaur.apache.org) (209.237.227.194) by apache.org (qpsmtpd/0.29) with SMTP; Wed, 23 Nov 2005 05:37:27 -0800 Received: (qmail 67614 invoked by uid 65534); 23 Nov 2005 13:35:34 -0000 Message-ID: <20051123133534.67610.qmail@minotaur.apache.org> Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r348436 - /directory/shared/ldap/trunk/apache2-provider/src/test/org/apache/asn1new/ldap/codec/AbandonRequestTest.java Date: Wed, 23 Nov 2005 13:35:34 -0000 To: commits@directory.apache.org From: elecharny@apache.org X-Mailer: svnmailer-1.0.5 X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N Author: elecharny Date: Wed Nov 23 05:35:29 2005 New Revision: 348436 URL: http://svn.apache.org/viewcvs?rev=348436&view=rev Log: Fixed the test accordingly to the modification done in Controls Modified: directory/shared/ldap/trunk/apache2-provider/src/test/org/apache/asn1new/ldap/codec/AbandonRequestTest.java Modified: directory/shared/ldap/trunk/apache2-provider/src/test/org/apache/asn1new/ldap/codec/AbandonRequestTest.java URL: http://svn.apache.org/viewcvs/directory/shared/ldap/trunk/apache2-provider/src/test/org/apache/asn1new/ldap/codec/AbandonRequestTest.java?rev=348436&r1=348435&r2=348436&view=diff ============================================================================== --- directory/shared/ldap/trunk/apache2-provider/src/test/org/apache/asn1new/ldap/codec/AbandonRequestTest.java (original) +++ directory/shared/ldap/trunk/apache2-provider/src/test/org/apache/asn1new/ldap/codec/AbandonRequestTest.java Wed Nov 23 05:35:29 2005 @@ -102,33 +102,32 @@ { Asn1Decoder ldapDecoder = new LdapDecoder(); - ByteBuffer stream = ByteBuffer.allocate( 0x48 ); + ByteBuffer stream = ByteBuffer.allocate( 0x64 ); stream.put( new byte[] { - 0x30, 0x46, // LDAPMessage ::=SEQUENCE { + 0x30, 0x62, // LDAPMessage ::=SEQUENCE { 0x02, 0x01, 0x03, // messageID MessageID 0x50, 0x01, 0x02, // CHOICE { ..., abandonRequest AbandonRequest,... - (byte)0xA0, 0x3E, // controls [0] Controls OPTIONAL } - //0x30, 0x3E, // Controls ::= SEQUENCE OF Control - 0x30, 0x13, // Control ::= SEQUENCE { + (byte)0xA0, 0x5A, // controls [0] Controls OPTIONAL } + 0x30, 0x1A, // Control ::= SEQUENCE { // controlType LDAPOID, - 0x04, 0x06, 0x2b, 0x06, 0x01, 0x05, 0x05, 0x01, + 0x04, 0x0D, '1', '.', '3', '.', '6', '.', '1', '.', '5', '.', '5', '.', '1', 0x01, 0x01, (byte)0xFF, // criticality BOOLEAN DEFAULT FALSE, // controlValue OCTET STRING OPTIONAL } 0x04, 0x06, 'a', 'b', 'c', 'd', 'e', 'f', - 0x30, 0x10, // Control ::= SEQUENCE { + 0x30, 0x17, // Control ::= SEQUENCE { // controlType LDAPOID, - 0x04, 0x06, 0x2b, 0x06, 0x01, 0x05, 0x05, 0x02, + 0x04, 0x0D, '1', '.', '3', '.', '6', '.', '1', '.', '5', '.', '5', '.', '2', // controlValue OCTET STRING OPTIONAL } 0x04, 0x06, 'g', 'h', 'i', 'j', 'k', 'l', - 0x30, 0x0B, // Control ::= SEQUENCE { + 0x30, 0x12, // Control ::= SEQUENCE { // controlType LDAPOID, - 0x04, 0x06, 0x2b, 0x06, 0x01, 0x05, 0x05, 0x03, + 0x04, 0x0D, '1', '.', '3', '.', '6', '.', '1', '.', '5', '.', '5', '.', '3', 0x01, 0x01, (byte)0xFF, // criticality BOOLEAN DEFAULT FALSE} - 0x30, 0x08, // Control ::= SEQUENCE { + 0x30, 0x0F, // Control ::= SEQUENCE { // controlType LDAPOID} - 0x04, 0x06, 0x2b, 0x06, 0x01, 0x05, 0x05, 0x04 + 0x04, 0x0D, '1', '.', '3', '.', '6', '.', '1', '.', '5', '.', '5', '.', '4' } ); String decodedPdu = StringUtils.dumpBytes( stream.array() ); @@ -156,7 +155,7 @@ Assert.assertEquals( 2, abandonRequest.getAbandonedMessageId() ); // Check the length - Assert.assertEquals(0x48, message.computeLength()); + Assert.assertEquals(0x64, message.computeLength()); // Check the encoding try