| OLD | NEW |
| 1 <html> | 1 <html> |
| 2 <head> | 2 <head> |
| 3 <script src="../inspector-test.js"></script> | 3 <script src="../inspector-test.js"></script> |
| 4 <script src="../network-test.js"></script> | 4 <script src="../network-test.js"></script> |
| 5 <script> | 5 <script> |
| 6 | 6 |
| 7 function test() | 7 function test() |
| 8 { | 8 { |
| 9 var networkPanel = WebInspector.inspectorView.showPanel("network"); | 9 var networkPanel = WebInspector.inspectorView.showPanel("network"); |
| 10 | 10 |
| (...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 54 var replayedRequest = lastRequest(); | 54 var replayedRequest = lastRequest(); |
| 55 assertRequestEqual(originalRequest, replayedRequest); | 55 assertRequestEqual(originalRequest, replayedRequest); |
| 56 callback(); | 56 callback(); |
| 57 } | 57 } |
| 58 } | 58 } |
| 59 | 59 |
| 60 | 60 |
| 61 InspectorTest.runTestSuite([ | 61 InspectorTest.runTestSuite([ |
| 62 function testGetStaticAsync(next) | 62 function testGetStaticAsync(next) |
| 63 { | 63 { |
| 64 testXHRReplay("GET", "resources/empty.html", true, "user", "password
", [["headerName", "headerValue"]], false, undefined, undefined, next); | 64 testXHRReplay("GET", "resources/empty.html", true, "user", "password
", [["headerName", "headerValueA"]], false, undefined, undefined, next); |
| 65 }, | 65 }, |
| 66 | 66 |
| 67 function testGetStaticSync(next) | 67 function testGetStaticSync(next) |
| 68 { | 68 { |
| 69 testXHRReplay("GET", "resources/empty.html", false, "user", "passwor
d", [["headerName", "headerValue"]], false, undefined, undefined, next); | 69 testXHRReplay("GET", "resources/empty.html", false, "user", "passwor
d", [["headerName", "headerValueB"]], false, undefined, undefined, next); |
| 70 }, | 70 }, |
| 71 | 71 |
| 72 function testGetCachedAsync(next) | 72 function testGetCachedAsync(next) |
| 73 { | 73 { |
| 74 testXHRReplay("GET", "resources/random-cached.php", true, "user", "p
assword", [["headerName", "headerValue"]], false, undefined, undefined, next); | 74 testXHRReplay("GET", "resources/random-cached.php", true, "user", "p
assword", [["headerName", "headerValueC"]], false, undefined, undefined, next); |
| 75 }, | 75 }, |
| 76 | 76 |
| 77 function testGetCachedSync(next) | 77 function testGetCachedSync(next) |
| 78 { | 78 { |
| 79 testXHRReplay("GET", "resources/random-cached.php", false, "user", "
password", [["headerName", "headerValue"]], false, undefined, undefined, next); | 79 testXHRReplay("GET", "resources/random-cached.php", false, "user", "
password", [["headerName", "headerValueD"]], false, undefined, undefined, next); |
| 80 }, | 80 }, |
| 81 | 81 |
| 82 function testGetRandomAsync(next) | 82 function testGetRandomAsync(next) |
| 83 { | 83 { |
| 84 testXHRReplay("GET", "resources/random.php", true, "user", "password
", [["headerName", "headerValue"]], false, undefined, undefined, next); | 84 testXHRReplay("GET", "resources/random.php", true, "user", "password
", [["headerName", "headerValueE"]], false, undefined, undefined, next); |
| 85 }, | 85 }, |
| 86 | 86 |
| 87 function testGetRandomSync(next) | 87 function testGetRandomSync(next) |
| 88 { | 88 { |
| 89 testXHRReplay("GET", "resources/random.php", false, "user", "passwor
d", [["headerName", "headerValue"]], false, undefined, undefined, next); | 89 testXHRReplay("GET", "resources/random.php", false, "user", "passwor
d", [["headerName", "headerValueF"]], false, undefined, undefined, next); |
| 90 }, | 90 }, |
| 91 | 91 |
| 92 function testPostAsync(next) | 92 function testPostAsync(next) |
| 93 { | 93 { |
| 94 testXHRReplay("POST", "resources/random.php", true, "user", "passwor
d", [["headerName", "headerValue"]], false, "payload", undefined, next); | 94 testXHRReplay("POST", "resources/random.php", true, "user", "passwor
d", [["headerName", "headerValueG"]], false, "payload", undefined, next); |
| 95 }, | 95 }, |
| 96 | 96 |
| 97 function testPostSync(next) | 97 function testPostSync(next) |
| 98 { | 98 { |
| 99 testXHRReplay("POST", "resources/random.php", false, "user", "passwo
rd", [["headerName", "headerValue"]], false, "payload", undefined, next); | 99 testXHRReplay("POST", "resources/random.php", false, "user", "passwo
rd", [["headerName", "headerValueH"]], false, "payload", undefined, next); |
| 100 } | 100 } |
| 101 ]); | 101 ]); |
| 102 } | 102 } |
| 103 </script> | 103 </script> |
| 104 </head> | 104 </head> |
| 105 <body onload="runTest()"> | 105 <body onload="runTest()"> |
| 106 Tests XHR replaying. | 106 Tests XHR replaying. |
| 107 <a href="https://bugs.webkit.org/show_bug.cgi?id=95187">Bug 95187</a> | 107 <a href="https://bugs.webkit.org/show_bug.cgi?id=95187">Bug 95187</a> |
| 108 </body> | 108 </body> |
| 109 </html> | 109 </html> |
| OLD | NEW |