equal
deleted
inserted
replaced
23 |
23 |
24 /** |
24 /** |
25 * @test |
25 * @test |
26 * @bug 4722333 |
26 * @bug 4722333 |
27 * @library ../../../sun/net/www/httptest/ |
27 * @library ../../../sun/net/www/httptest/ |
28 * @build HttpCallback HttpServer ClosedChannelList HttpTransaction |
28 * @build HttpCallback TestHttpServer ClosedChannelList HttpTransaction |
29 * @run main B4722333 |
29 * @run main B4722333 |
30 * @summary JRE Proxy Authentication Not Working with ISA2000 |
30 * @summary JRE Proxy Authentication Not Working with ISA2000 |
31 */ |
31 */ |
32 |
32 |
33 import java.io.*; |
33 import java.io.*; |
112 InputStream is = urlc.getInputStream (); |
112 InputStream is = urlc.getInputStream (); |
113 read (is); |
113 read (is); |
114 is.close(); |
114 is.close(); |
115 } |
115 } |
116 |
116 |
117 static HttpServer server; |
117 static TestHttpServer server; |
118 |
118 |
119 public static void main (String[] args) throws Exception { |
119 public static void main (String[] args) throws Exception { |
120 MyAuthenticator auth = new MyAuthenticator (); |
120 MyAuthenticator auth = new MyAuthenticator (); |
121 Authenticator.setDefault (auth); |
121 Authenticator.setDefault (auth); |
122 try { |
122 try { |
123 server = new HttpServer (new B4722333(), 1, 10, 0); |
123 server = new TestHttpServer (new B4722333(), 1, 10, 0); |
124 System.out.println ("Server started: listening on port: " + server.getLocalPort()); |
124 System.out.println ("Server started: listening on port: " + server.getLocalPort()); |
125 client ("http://localhost:"+server.getLocalPort()+"/d1/d2/d3/foo.html"); |
125 client ("http://localhost:"+server.getLocalPort()+"/d1/d2/d3/foo.html"); |
126 client ("http://localhost:"+server.getLocalPort()+"/ASD/d3/x.html"); |
126 client ("http://localhost:"+server.getLocalPort()+"/ASD/d3/x.html"); |
127 client ("http://localhost:"+server.getLocalPort()+"/biz/d3/x.html"); |
127 client ("http://localhost:"+server.getLocalPort()+"/biz/d3/x.html"); |
128 client ("http://localhost:"+server.getLocalPort()+"/bar/d3/x.html"); |
128 client ("http://localhost:"+server.getLocalPort()+"/bar/d3/x.html"); |