Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(533)

Side by Side Diff: chrome/test/data/extensions/api_test/webrequest/test_complex.html

Issue 7982023: Fixed ExtraInfoSpec flags for webRequest.onAuthRequired (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Also improve browser tests Created 9 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « chrome/browser/extensions/extension_webrequest_api.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 <script src="framework.js"> 1 <script src="framework.js">
2 </script> 2 </script>
3 <script> 3 <script>
4 // Constants as functions, not to be called until after runTests. 4 // Constants as functions, not to be called until after runTests.
5 function getURLAuthRequired() { 5 function getURLAuthRequired() {
6 return getServerURL('auth-basic'); 6 return getServerURL('auth-basic');
7 } 7 }
8 function getURLHttpXHR() { 8 function getURLHttpXHR() {
9 return getServerURL('files/extensions/api_test/webrequest/xhr/a.html'); 9 return getServerURL('files/extensions/api_test/webrequest/xhr/a.html');
10 } 10 }
(...skipping 209 matching lines...) Expand 10 before | Expand all | Expand 10 after
220 url: getURLAuthRequired(), 220 url: getURLAuthRequired(),
221 } 221 }
222 }, 222 },
223 { label: "onAuthRequired", 223 { label: "onAuthRequired",
224 event: "onAuthRequired", 224 event: "onAuthRequired",
225 details: { 225 details: {
226 url: getURLAuthRequired(), 226 url: getURLAuthRequired(),
227 isProxy: false, 227 isProxy: false,
228 scheme: "basic", 228 scheme: "basic",
229 realm: "testrealm", 229 realm: "testrealm",
230 challenger: {host: testServer, port: testServerPort} 230 challenger: {host: testServer, port: testServerPort},
231 responseHeadersExist: true
231 } 232 }
232 }, 233 },
233 { label: "onResponseStarted", 234 { label: "onResponseStarted",
234 event: "onResponseStarted", 235 event: "onResponseStarted",
235 details: { 236 details: {
236 url: getURLAuthRequired(), 237 url: getURLAuthRequired(),
237 fromCache: false, 238 fromCache: false,
238 statusCode: 401, 239 statusCode: 401,
239 ip: "127.0.0.1" 240 ip: "127.0.0.1",
241 responseHeadersExist: true
240 } 242 }
241 }, 243 },
242 { label: "onCompleted", 244 { label: "onCompleted",
243 event: "onCompleted", 245 event: "onCompleted",
244 details: { 246 details: {
245 url: getURLAuthRequired(), 247 url: getURLAuthRequired(),
246 fromCache: false, 248 fromCache: false,
247 statusCode: 401, 249 statusCode: 401,
248 ip: "127.0.0.1" 250 ip: "127.0.0.1",
251 responseHeadersExist: true
249 } 252 }
250 }, 253 },
251 ], 254 ],
252 [ // event order 255 [ // event order
253 ["onBeforeRequest", "onBeforeSendHeaders", "onSendHeaders", 256 ["onBeforeRequest", "onBeforeSendHeaders", "onSendHeaders",
254 "onAuthRequired", "onResponseStarted", "onCompleted"] 257 "onAuthRequired", "onResponseStarted", "onCompleted"]
255 ], 258 ],
256 {}, []); 259 {}, ["responseHeaders"]);
257 navigateAndWait(getURLAuthRequired()); 260 navigateAndWait(getURLAuthRequired());
258 }, 261 },
259 262
260 // Navigates to a page to generates an XHR. 263 // Navigates to a page to generates an XHR.
261 function xhrLoad() { 264 function xhrLoad() {
262 expect( 265 expect(
263 [ // events 266 [ // events
264 { label: "onBeforeRequest-1", 267 { label: "onBeforeRequest-1",
265 event: "onBeforeRequest", 268 event: "onBeforeRequest",
266 details: { 269 details: {
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after
345 [ // event order 348 [ // event order
346 ["onBeforeRequest-1", "onBeforeSendHeaders-1", "onSendHeaders-1", 349 ["onBeforeRequest-1", "onBeforeSendHeaders-1", "onSendHeaders-1",
347 "onResponseStarted-1", "onCompleted-1", 350 "onResponseStarted-1", "onCompleted-1",
348 "onBeforeRequest-2", "onBeforeSendHeaders-2", "onSendHeaders-2", 351 "onBeforeRequest-2", "onBeforeSendHeaders-2", "onSendHeaders-2",
349 "onResponseStarted-2", "onCompleted-2"] ], 352 "onResponseStarted-2", "onCompleted-2"] ],
350 {}, []); 353 {}, []);
351 navigateAndWait(getURLHttpXHR()); 354 navigateAndWait(getURLHttpXHR());
352 }, 355 },
353 ]); 356 ]);
354 </script> 357 </script>
OLDNEW
« no previous file with comments | « chrome/browser/extensions/extension_webrequest_api.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698