harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Artem Aliev (JIRA)" <j...@apache.org>
Subject [jira] Created: (HARMONY-2413) [luni] java.net.Authenticator.getRequestorType returns null while RI returns valid result
Date Mon, 04 Dec 2006 12:06:21 GMT
[luni] java.net.Authenticator.getRequestorType returns null while RI returns valid result
-----------------------------------------------------------------------------------------

                 Key: HARMONY-2413
                 URL: http://issues.apache.org/jira/browse/HARMONY-2413
             Project: Harmony
          Issue Type: Bug
          Components: Classlib
            Reporter: Artem Aliev
            Priority: Minor


import junit.framework.TestCase;
import java.net.Authenticator;
import java.net.*;

public class test extends TestCase 
{
        public void testcase0() 
        {
                TestAuthentificator localTestAuthentificator = new
TestAuthentificator();
                InetAddress in = null;
                try
                {
                        in = InetAddress.getLocalHost();
                }
                catch (UnknownHostException e)
                {
                        e.printStackTrace();
                }
                Authenticator.setDefault(localTestAuthentificator);
                Authenticator.requestPasswordAuthentication(in, -1, "http",
"promt", "HTTP");
                Authenticator.RequestorType returnValue =
localTestAuthentificator.getRequestorTypetest();
                System.out.println("Authenticator.RequestorType ="
+returnValue);
                assertNotNull(returnValue);
        }
}

 class TestAuthentificator extends Authenticator 
{
        public TestAuthentificator() 
        {super();
        }
         public Authenticator.RequestorType getRequestorTypetest()
         {return getRequestorType();

         }
}


-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Mime
View raw message