Move parseFontFaceDescriptor to CSSPropertyParser.cpp
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / inspector / load-file-resource-for-frontend.html
blobbe3561fff3fc4327c29ea6aef7dcbdfd8ad1fb9f
1 <html>
2 <head>
3 <script src="../http/tests/inspector/inspector-test.js"></script>
4 <script>
5 function test()
7 function testLoadForURL(url, next)
9 var documentURL = InspectorTest.resourceTreeModel.mainFrame.url;
10 var lastIndexOfSlash = documentURL.lastIndexOf("/");
11 var urlPrefix = documentURL.substr(0, lastIndexOfSlash + 1);
12 var fullURL = urlPrefix + url;
13 InspectorTest.addResult("Loading resource from " + url);
15 WebInspector.ResourceLoader.load(fullURL, null, callback);
17 function callback(statusCode, headers, content)
19 if (!content)
20 InspectorTest.addResult("Failed: " + statusCode);
21 else {
22 InspectorTest.addResult("Content: " + content);
24 InspectorTest.runAfterPendingDispatches(next);
28 InspectorTest.runTestSuite([
29 function testResourceFromFileScheme(next)
31 testLoadForURL("resources/file-resource-to-load-for-frontend.txt", next);
33 ]);
35 </script>
36 </head>
37 <body onload="runTest()">
38 </body>
39 </html>