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

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

Issue 2385093002: DevTools: introduce Trie data structure (Closed)
Patch Set: address comments Created 4 years, 2 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/http/tests/inspector-unit/trie.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-unit/inspector-unit-test.js
diff --git a/third_party/WebKit/LayoutTests/http/tests/inspector-unit/inspector-unit-test.js b/third_party/WebKit/LayoutTests/http/tests/inspector-unit/inspector-unit-test.js
index ccda7a9536991c889b8d9c187d28e8a693aa5846..93b5ca175e010d4b17260805fa34e379afdfd678 100644
--- a/third_party/WebKit/LayoutTests/http/tests/inspector-unit/inspector-unit-test.js
+++ b/third_party/WebKit/LayoutTests/http/tests/inspector-unit/inspector-unit-test.js
@@ -56,6 +56,25 @@ var UnitTest = {};
console.log(text);
}
+ UnitTest.runTests = function(tests)
+ {
+ nextTest();
+
+ function nextTest()
+ {
+ var test = tests.shift();
+ if (!test) {
+ UnitTest.completeTest();
+ return;
+ }
+ UnitTest.addResult("\ntest: " + test.name);
+ var testPromise = test();
+ if (!(testPromise instanceof Promise))
+ testPromise = Promise.resolve();
+ testPromise.then(nextTest);
+ }
+ }
+
function completeTestOnError(message, source, lineno, colno, error)
{
UnitTest.addResult("TEST ENDED IN ERROR: " + error.stack);
@@ -93,4 +112,4 @@ var UnitTest = {};
test();
}
-})();
+})();
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/http/tests/inspector-unit/trie.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698