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

Side by Side Diff: sky/tests/inspector/page-agent-get-resource-tree.sky

Issue 742813002: Attempt to fix page-agent-get-resource-tree on the bot (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 6 years, 1 month 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
« no previous file with comments | « no previous file | 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 <html> 1 <html>
2 <import src="/sky/tests/resources/chai.sky" /> 2 <import src="/sky/tests/resources/chai.sky" />
3 <import src="/sky/tests/resources/mocha.sky" /> 3 <import src="/sky/tests/resources/mocha.sky" />
4 <import src="/sky/framework/inspector/page-agent.sky" as="PageAgent" /> 4 <import src="/sky/framework/inspector/page-agent.sky" as="PageAgent" />
5 <img src='does_not_exist.jpg' /> 5 <img src='does_not_exist.jpg' />
6 <script> 6 <script>
7 // This is to avoid hard-coding the hostname and port number in the tests.
8 function absoluteURL(url) {
9 return String(new URL(url, document.URL));
10 }
11
7 describe('PageAgent.getResourceTree', function() { 12 describe('PageAgent.getResourceTree', function() {
8 it('should dump the current resource tree', function() { 13 it('should dump the current resource tree', function() {
9 var pageAgent = new PageAgent(); 14 var pageAgent = new PageAgent();
10 pageAgent.enable(); 15 pageAgent.enable();
11 var resourceTree = pageAgent.getResourceTree(); 16 var resourceTree = pageAgent.getResourceTree();
12 assert.deepEqual(resourceTree, { 17 assert.deepEqual(resourceTree, {
13 "frameTree": { 18 "frameTree": {
14 "frame": { 19 "frame": {
15 "id": "1", 20 "id": "1",
16 "loaderId": "1", 21 "loaderId": "1",
17 "url": "http://127.0.0.1:8000/sky/tests/inspector/page-agent-get-resou rce-tree.sky", 22 "url": absoluteURL("/sky/tests/inspector/page-agent-get-resource-tree. sky"),
18 "mimeType": "text/html", 23 "mimeType": "text/html",
19 "securityOrigin": "http://127.0.0.1:8000/sky/tests/inspector/page-agen t-get-resource-tree.sky" 24 "securityOrigin": absoluteURL("/sky/tests/inspector/page-agent-get-res ource-tree.sky")
20 }, 25 },
21 "resources": [{ 26 "resources": [{
22 "url": "http://127.0.0.1:8000/sky/tests/resources/chai.sky", 27 "url": absoluteURL("/sky/tests/resources/chai.sky"),
23 "type": "Document", 28 "type": "Document",
24 "mimeType": "text/html" 29 "mimeType": "text/html"
25 }, { 30 }, {
26 "url": "http://127.0.0.1:8000/sky/tests/resources/mocha.sky", 31 "url": absoluteURL("/sky/tests/resources/mocha.sky"),
27 "type": "Document", 32 "type": "Document",
28 "mimeType": "text/html" 33 "mimeType": "text/html"
29 }, { 34 }, {
30 "url": "http://127.0.0.1:8000/sky/framework/inspector/page-agent.sky", 35 "url": absoluteURL("/sky/framework/inspector/page-agent.sky"),
31 "type": "Document", 36 "type": "Document",
32 "mimeType": "text/html" 37 "mimeType": "text/html"
33 }, { 38 }, {
34 "url": "http://127.0.0.1:8000/sky/tests/inspector/does_not_exist.jpg", 39 "url": absoluteURL("/sky/tests/inspector/does_not_exist.jpg"),
35 "type": "Image", 40 "type": "Image",
36 "mimeType": "image/unknown" 41 "mimeType": "image/unknown"
37 }] 42 }]
38 } 43 }
39 }); 44 });
40 }); 45 });
41 }); 46 });
42 </script> 47 </script>
43 </html> 48 </html>
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698