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

Side by Side Diff: third_party/WebKit/LayoutTests/http/tests/inspector/console-test.js

Issue 2916743002: [DevTools] Introduce Common.List used as a backend for list controls (Closed)
Patch Set: addressed comments Created 3 years, 6 months 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 unified diff | Download patch
OLDNEW
1 var initialize_ConsoleTest = function() { 1 var initialize_ConsoleTest = function() {
2 2
3 InspectorTest.preloadModule("source_frame"); 3 InspectorTest.preloadModule("source_frame");
4 InspectorTest.preloadPanel("console"); 4 InspectorTest.preloadPanel("console");
5 5
6 InspectorTest.selectMainExecutionContext = function() 6 InspectorTest.selectMainExecutionContext = function()
7 { 7 {
8 var executionContexts = InspectorTest.runtimeModel.executionContexts(); 8 var executionContexts = InspectorTest.runtimeModel.executionContexts();
9 for (var context of executionContexts) { 9 for (var context of executionContexts) {
10 if (context.isDefault) { 10 if (context.isDefault) {
(...skipping 377 matching lines...) Expand 10 before | Expand all | Expand 10 after
388 { 388 {
389 var callback; 389 var callback;
390 var promise = new Promise((fullfill) => callback = fullfill); 390 var promise = new Promise((fullfill) => callback = fullfill);
391 InspectorTest.waitUntilNthMessageReceived(count, callback); 391 InspectorTest.waitUntilNthMessageReceived(count, callback);
392 return promise; 392 return promise;
393 } 393 }
394 394
395 InspectorTest.changeExecutionContext = function(namePrefix) 395 InspectorTest.changeExecutionContext = function(namePrefix)
396 { 396 {
397 var selector = Console.ConsoleView.instance()._consoleContextSelector; 397 var selector = Console.ConsoleView.instance()._consoleContextSelector;
398 for (var executionContext of selector._list._items) { 398 for (var executionContext of selector._items._items) {
399 if (selector._titleFor(executionContext).startsWith(namePrefix)) { 399 if (selector._titleFor(executionContext).startsWith(namePrefix)) {
400 UI.context.setFlavor(SDK.ExecutionContext, executionContext); 400 UI.context.setFlavor(SDK.ExecutionContext, executionContext);
401 return; 401 return;
402 } 402 }
403 } 403 }
404 InspectorTest.addResult("FAILED: context with prefix: " + namePrefix + " no t found in the context list"); 404 InspectorTest.addResult("FAILED: context with prefix: " + namePrefix + " no t found in the context list");
405 } 405 }
406 406
407 InspectorTest.waitForConsoleMessages = function(expectedCount, callback) 407 InspectorTest.waitForConsoleMessages = function(expectedCount, callback)
408 { 408 {
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
441 offset: offset - charCount 441 offset: offset - charCount
442 }; 442 };
443 } 443 }
444 charCount += length; 444 charCount += length;
445 } 445 }
446 return null; 446 return null;
447 } 447 }
448 } 448 }
449 449
450 } 450 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698