| <html> |
| <head> |
| <style> |
| div.marker::before { |
| content: url(resources/test.bmp); |
| } |
| </style> |
| <script src="../../http/tests/inspector/inspector-test.js"></script> |
| <script src="../../http/tests/inspector/timeline-test.js"></script> |
| <script> |
| |
| function doActions() |
| { |
| var callback; |
| var promise = new Promise((fulfill) => callback = fulfill); |
| document.getElementById("marker").classList.add("marker"); |
| var img = document.createElement("img"); |
| img.src = "resources/test.bmp"; |
| img.addEventListener("load", onImageLoaded, false); |
| function onImageLoaded() |
| { |
| testRunner.layoutAndPaintAsyncThen(callback); |
| } |
| return promise; |
| } |
| |
| function test() |
| { |
| InspectorTest.invokeAsyncWithTimeline("doActions", onRecordingDone); |
| |
| function onRecordingDone() |
| { |
| InspectorTest.addResult("DONE"); |
| InspectorTest.completeTest(); |
| } |
| } |
| </script> |
| </head> |
| |
| <body onload="runTest()"> |
| <p> |
| Tests the Timeline instrumentation does not crash the renderer upon encountering an anonymous image render object |
| </p> |
| <div id="marker"></div> |
| </body> |
| </html> |