Web Inspector: add a regression test for the fix introduced in r188679
authorbburg@apple.com <bburg@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 21 Aug 2015 17:05:59 +0000 (17:05 +0000)
committerbburg@apple.com <bburg@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 21 Aug 2015 17:05:59 +0000 (17:05 +0000)
https://bugs.webkit.org/show_bug.cgi?id=148223

Reviewed by Joseph Pecoraro.

Source/WebInspectorUI:

Turns out that we were possibly leaking a single DOMTree on reload.
Always clear the main frame's DOMTree as well as those of sub-frames.

* UserInterface/Base/Object.js: Add back single-fire listeners.
(WebInspector.Object.singleFireEventListener.let.wrappedCallback):
(WebInspector.Object.singleFireEventListener):
(WebInspector.Object.retainedObjectsWithPrototype):
(WebInspector.Object.prototype.singleFireEventListener):
(WebInspector.Object.prototype.retainedObjectsWithPrototype):
* UserInterface/Models/Frame.js:
(WebInspector.Frame.prototype.removeAllChildFrames): Clear own tree too.

LayoutTests:

Add a regression test to check the number of DOMTree instances that
listen to DOMTreeManager.

* TestExpectations: Don't skip the inspector/dom/ directory.
* http/tests/inspector/dom/disconnect-dom-tree-after-main-frame-navigation-expected.txt: Added.
* http/tests/inspector/dom/disconnect-dom-tree-after-main-frame-navigation.html: Added.
* http/tests/inspector/dom/resources/nested-frame-1-deep.html: Added.
* http/tests/inspector/dom/resources/nested-frame-2-deep.html: Added.
* http/tests/inspector/dom/resources/nested-frame-base.html: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@188756 268f45cc-cd09-0410-ab3c-d52691b4dbfc


No differences found