Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(92)

Unified Diff: third_party/WebKit/LayoutTests/http/tests/inspector/inspector-test.js

Issue 2574603002: DevTools: Fix Elements tab event listener removal (Closed)
Patch Set: address feedback Created 4 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/LayoutTests/http/tests/inspector/inspector-test.js
diff --git a/third_party/WebKit/LayoutTests/http/tests/inspector/inspector-test.js b/third_party/WebKit/LayoutTests/http/tests/inspector/inspector-test.js
index 518f686550c3770b24a824cd6143f1a4e859e245..58c45f431c81cd687a42a27d4841302101957958 100644
--- a/third_party/WebKit/LayoutTests/http/tests/inspector/inspector-test.js
+++ b/third_party/WebKit/LayoutTests/http/tests/inspector/inspector-test.js
@@ -319,10 +319,8 @@ InspectorTest.dumpObjectPropertyTreeElement = function(treeElement)
}
}
-InspectorTest.expandAndDumpEventListeners = function(eventListenersView, callback)
+InspectorTest.expandAndDumpEventListeners = function(eventListenersView, callback, force)
{
- InspectorTest.addSniffer(Components.EventListenersView.prototype, "_eventListenersArrivedForTest", listenersArrived);
-
function listenersArrived()
{
var listenerTypes = eventListenersView._treeOutline.rootElement().children();
@@ -352,6 +350,11 @@ InspectorTest.expandAndDumpEventListeners = function(eventListenersView, callbac
}
callback();
}
+
+ if (force)
+ listenersArrived();
+ else
+ InspectorTest.addSniffer(Components.EventListenersView.prototype, "_eventListenersArrivedForTest", listenersArrived);
}
InspectorTest.dumpNavigatorView = function(navigatorView)

Powered by Google App Engine
This is Rietveld 408576698