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

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

Issue 2466123002: DevTools: reformat front-end code to match chromium style. (Closed)
Patch Set: all done Created 4 years, 1 month 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
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/inspector/components/widget-events.html » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/LayoutTests/http/tests/inspector/workspace-test.js
diff --git a/third_party/WebKit/LayoutTests/http/tests/inspector/workspace-test.js b/third_party/WebKit/LayoutTests/http/tests/inspector/workspace-test.js
index 6e93bb71edb69f789e66e1ffbb08f20485b10572..cf1fe0675d0ed0e70a500f7a236296d26c958c89 100644
--- a/third_party/WebKit/LayoutTests/http/tests/inspector/workspace-test.js
+++ b/third_party/WebKit/LayoutTests/http/tests/inspector/workspace-test.js
@@ -42,30 +42,27 @@ InspectorTest._pageCapabilities =
InspectorTest.createMockTarget = function(id, debuggerModelConstructor, capabilities)
{
capabilities = capabilities || InspectorTest._pageCapabilities;
- var MockTarget = function(name, connectionFactory, callback)
- {
- WebInspector.Target.call(this, InspectorTest.testTargetManager, name, capabilities, connectionFactory, null, callback);
- this._inspectedURL = InspectorTest.mainTarget.inspectedURL();
- this.consoleModel = new WebInspector.ConsoleModel(this);
- this.networkManager = new WebInspector.NetworkManager(this);
- this.runtimeModel = new WebInspector.RuntimeModel(this);
- this.securityOriginManager = WebInspector.SecurityOriginManager.fromTarget(this);
- this.resourceTreeModel = new WebInspector.ResourceTreeModel(this, this.networkManager, this.securityOriginManager);
- this.resourceTreeModel._cachedResourcesProcessed = true;
- this.resourceTreeModel._frameAttached("42", 0);
- this.debuggerModel = debuggerModelConstructor ? new debuggerModelConstructor(this) : new WebInspector.DebuggerModel(this);
- this._modelByConstructor.set(WebInspector.DebuggerModel, this.debuggerModel);
- this.domModel = new WebInspector.DOMModel(this);
- this.cssModel = new WebInspector.CSSModel(this, this.domModel);
- }
+ var MockTarget = class extends WebInspector.Target {
+ constructor(name, connectionFactory, callback) {
+ super(InspectorTest.testTargetManager, name, capabilities, connectionFactory, null, callback);
+ this._inspectedURL = InspectorTest.mainTarget.inspectedURL();
+ this.consoleModel = new WebInspector.ConsoleModel(this);
+ this.networkManager = new WebInspector.NetworkManager(this);
+ this.runtimeModel = new WebInspector.RuntimeModel(this);
+ this.securityOriginManager = WebInspector.SecurityOriginManager.fromTarget(this);
+ this.resourceTreeModel = new WebInspector.ResourceTreeModel(this, this.networkManager, this.securityOriginManager);
+ this.resourceTreeModel._cachedResourcesProcessed = true;
+ this.resourceTreeModel._frameAttached("42", 0);
+ this.debuggerModel = debuggerModelConstructor ? new debuggerModelConstructor(this) : new WebInspector.DebuggerModel(this);
+ this._modelByConstructor.set(WebInspector.DebuggerModel, this.debuggerModel);
+ this.domModel = new WebInspector.DOMModel(this);
+ this.cssModel = new WebInspector.CSSModel(this, this.domModel);
+ }
- MockTarget.prototype = {
- _loadedWithCapabilities: function()
+ _loadedWithCapabilities()
{
- },
-
- __proto__: WebInspector.Target.prototype
- }
+ }
+ };
var target = new MockTarget("mock-target-" + id, (params) => new WebInspector.StubConnection(params));
InspectorTest.testTargetManager.addTarget(target);
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/inspector/components/widget-events.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698