Commit 74b64b50 authored by mnaganov@chromium.org's avatar mnaganov@chromium.org
Browse files

Revert "2011-01-18 Mikhail Naganov <mnaganov@chromium.org>"

Revert r76114 -- added test fails on Chromium canaries.

This reverts commit 89065aef.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@76117 268f45cc-cd09-0410-ab3c-d52691b4dbfc
parent 42fc43f1
2011-01-19 Mikhail Naganov <mnaganov@chromium.org>
Revert r76114 -- added test fails on Chromium canaries.
2011-01-19 Alexander Pavlov <apavlov@chromium.org>
 
Reviewed by Pavel Feldman.
......
Tests that CPU profiling works. Bug 52634.
found pageFunction
<html>
<head>
<script src="../http/tests/inspector/inspector-test2.js"></script>
<script>
function pageFunction() {
console.profile("outer");
console.profile("inner"); // [Chromium] Make sure we capture the current callstack.
console.profileEnd("inner");
console.profileEnd("outer");
}
function initialize_ProfilerTests()
{
var oldAddProfileHeader = WebInspector.panels.profiles._addProfileHeader;
WebInspector.panels.profiles._addProfileHeader = function(profile)
{
oldAddProfileHeader.call(this, profile);
if (profile.title === "inner") {
this.showProfile(profile);
}
}
var oldRefresh = WebInspector.CPUProfileView.prototype.refresh;
WebInspector.CPUProfileView.prototype.refresh = function()
{
oldRefresh.call(this);
if (this.profile.title === "inner") {
var tree = this.profileDataGridTree;
if (!tree)
InspectorTest.addResult("no tree");
var node = tree.children[0];
if (!node)
InspectorTest.addResult("no node");
while (node) {
if (node.functionName.indexOf("pageFunction") !== -1) {
InspectorTest.addResult("found pageFunction");
break;
}
node = node.traverseNextNode(true, null, true);
}
InspectorTest.completeTest();
}
}
}
function test()
{
WebInspector.showPanel("profiles");
WebInspector.panels.profiles._enableProfiling();
InspectorBackend.startProfiling();
InspectorTest.evaluateInConsole("pageFunction()", function done()
{
InspectorBackend.stopProfiling();
});
}
</script>
</head>
<body onload="runTest()">
<p>
Tests that CPU profiling works.
<a href="https://bugs.webkit.org/show_bug.cgi?id=52634">Bug 52634.</a>
</p>
</body>
</html>
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment