directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From elecha...@apache.org
Subject svn commit: r1043017 - /directory/apacheds/branches/apacheds-kerberos-codec-2.0/kerberos-codec/src/test/java/org/apache/directory/server/kerberos/shared/messages/value/PrincipalNameTest.java
Date Tue, 07 Dec 2010 12:52:39 GMT
Author: elecharny
Date: Tue Dec  7 12:52:39 2010
New Revision: 1043017

URL: http://svn.apache.org/viewvc?rev=1043017&view=rev
Log:
Fixed the PrincipalName tests

Modified:
    directory/apacheds/branches/apacheds-kerberos-codec-2.0/kerberos-codec/src/test/java/org/apache/directory/server/kerberos/shared/messages/value/PrincipalNameTest.java

Modified: directory/apacheds/branches/apacheds-kerberos-codec-2.0/kerberos-codec/src/test/java/org/apache/directory/server/kerberos/shared/messages/value/PrincipalNameTest.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/apacheds-kerberos-codec-2.0/kerberos-codec/src/test/java/org/apache/directory/server/kerberos/shared/messages/value/PrincipalNameTest.java?rev=1043017&r1=1043016&r2=1043017&view=diff
==============================================================================
--- directory/apacheds/branches/apacheds-kerberos-codec-2.0/kerberos-codec/src/test/java/org/apache/directory/server/kerberos/shared/messages/value/PrincipalNameTest.java
(original)
+++ directory/apacheds/branches/apacheds-kerberos-codec-2.0/kerberos-codec/src/test/java/org/apache/directory/server/kerberos/shared/messages/value/PrincipalNameTest.java
Tue Dec  7 12:52:39 2010
@@ -44,7 +44,7 @@ public class PrincipalNameTest
     @Test
     public void testEncodingPrincipalNameOneName() throws Exception
     {
-        PrincipalName principal = new PrincipalName( "Test@APACHE", PrincipalNameType.KRB_NT_PRINCIPAL
);
+        PrincipalName principal = new PrincipalName( "Test", PrincipalNameType.KRB_NT_PRINCIPAL
);
 
         ByteBuffer encoded = ByteBuffer.allocate( principal.computeLength() );
 
@@ -68,7 +68,7 @@ public class PrincipalNameTest
     @Test
     public void testEncodingPrincipalName3names() throws Exception
     {
-        PrincipalName principal = new PrincipalName( "Test1@APACHE", PrincipalNameType.KRB_NT_PRINCIPAL
);
+        PrincipalName principal = new PrincipalName( "Test1", PrincipalNameType.KRB_NT_PRINCIPAL
);
         principal.addName( "Test2" );
         principal.addName( "Test3" );
 
@@ -106,11 +106,12 @@ public class PrincipalNameTest
 
         byte[] expectedResult = new byte[]
             { 
-              0x30, 0x09, 
+              0x30, 0x0B, 
                 ( byte ) 0xA0, 0x03, 
                   0x02, 0x01, 0x01, 
-                ( byte ) 0xA1, 0x02, 
-                  0x30, 0x00 
+                ( byte ) 0xA1, 0x04, 
+                  0x30, 0x02,
+                    0x1B, 0x00
             };
 
         assertEquals( StringTools.dumpBytes( expectedResult ), StringTools.dumpBytes( encoded.array()
) );



Mime
View raw message