| Index: LayoutTests/inspector/timeline/timeline-timer-fired-from-eval-call-site.html
|
| diff --git a/LayoutTests/inspector/timeline/timeline-timer-fired-from-eval-call-site.html b/LayoutTests/inspector/timeline/timeline-timer-fired-from-eval-call-site.html
|
| index 68b022bae6bfc0728fdfb99d7fbb1e2c73387044..9efdb175fa8ce6758f22deabf9beb8a4bb274144 100644
|
| --- a/LayoutTests/inspector/timeline/timeline-timer-fired-from-eval-call-site.html
|
| +++ b/LayoutTests/inspector/timeline/timeline-timer-fired-from-eval-call-site.html
|
| @@ -4,13 +4,20 @@
|
| <script src="../../http/tests/inspector/timeline-test.js"></script>
|
| <script>
|
|
|
| -function performActions()
|
| +function performActions(callback)
|
| {
|
| + window.callWhenDone = callback;
|
| var content = "" +
|
| - "var fn2 = function() {console.markTimeline(\"Script evaluated\");};\\n" +
|
| - "var fn1 = function() {window.setTimeout(fn2, 1);};\\n" +
|
| - "window.setTimeout(fn1, 1);\\n"
|
| - content = "eval('" + content + "//# sourceURL=fromEval.js" + "');";
|
| + "var fn2 = function() {" +
|
| + " console.markTimeline(\"Script evaluated\");" +
|
| + " window.callWhenDone();" +
|
| + "};\\n" +
|
| + "var fn1 = function() {" +
|
| + " window.setTimeout(fn2, 1);" +
|
| + "};\\n" +
|
| + "window.setTimeout(fn1, 1);\\n" +
|
| + "//# sourceURL=fromEval.js";
|
| + content = "eval('" + content + "');";
|
| var scriptElement = document.createElement('script');
|
| var contentNode = document.createTextNode(content);
|
| scriptElement.appendChild(contentNode);
|
| @@ -20,13 +27,7 @@ function performActions()
|
|
|
| function test()
|
| {
|
| - InspectorTest.startTimeline(start);
|
| - InspectorTest.waitForRecordType("TimeStamp", finish);
|
| -
|
| - function start()
|
| - {
|
| - InspectorTest.evaluateInPage("performActions()");
|
| - }
|
| + InspectorTest.invokeAsyncWithTimeline("performActions", finish);
|
|
|
| function finish()
|
| {
|
|
|