diff options
Diffstat (limited to 'webkit/glue')
-rw-r--r-- | webkit/glue/devtools/js/devtools.js | 14 | ||||
-rw-r--r-- | webkit/glue/devtools/js/tests.js | 25 |
2 files changed, 38 insertions, 1 deletions
diff --git a/webkit/glue/devtools/js/devtools.js b/webkit/glue/devtools/js/devtools.js index 9820c94..11f482f 100644 --- a/webkit/glue/devtools/js/devtools.js +++ b/webkit/glue/devtools/js/devtools.js @@ -487,4 +487,16 @@ WebInspector.ElementsPanel.prototype._nodeSearchButtonClicked = function( InspectorController.toggleNodeSearch(); this.nodeSearchButton.toggled = !this.nodeSearchButton.toggled; }; -})();
\ No newline at end of file +})(); + + +(function() { +// Temporary fix until fix for https://bugs.webkit.org/show_bug.cgi?id=31343 +// is landed. +var original = WebInspector.addDOMStorage; +WebInspector.addDOMStorage = function(payload) { + if (!this.panels.storage) + return; + return original.apply(this, arguments); +}; +})(); diff --git a/webkit/glue/devtools/js/tests.js b/webkit/glue/devtools/js/tests.js index e65ea9d..0a0cdd6 100644 --- a/webkit/glue/devtools/js/tests.js +++ b/webkit/glue/devtools/js/tests.js @@ -637,6 +637,31 @@ TestSuite.prototype.testPauseOnException = function() { }; +// Tests that debugger works correctly if pause event occurs when DevTools +// frontend is being loaded. +TestSuite.prototype.testPauseWhenLoadingDevTools = function() { + this.showPanel('scripts'); + var test = this; + + // Script execution can already be paused. + if (WebInspector.currentPanel.paused) { + var callFrame = + WebInspector.currentPanel.sidebarPanes.callstack.selectedCallFrame; + this.assertEquals('callDebugger', callFrame.functionName); + return; + } + + this.addSniffer( + WebInspector, + 'pausedScript', + function(callFrames) { + test.assertEquals('callDebugger', callFrames[0].functionName); + test.releaseControl(); + }); + this.takeControl(); +}; + + /** * Serializes options collection to string. * @param {HTMLOptionsCollection} options |