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

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

Issue 1733073002: Prepare inspector layout tests for ES2015 Function.name changes (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 10 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 | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/LayoutTests/http/tests/inspector/console-test.js
diff --git a/third_party/WebKit/LayoutTests/http/tests/inspector/console-test.js b/third_party/WebKit/LayoutTests/http/tests/inspector/console-test.js
index cb75b17809c2294624b5230ed0169d279d4ad9da..0635313c49e422d57f8ae2c4c6b2f512482c7a1e 100644
--- a/third_party/WebKit/LayoutTests/http/tests/inspector/console-test.js
+++ b/third_party/WebKit/LayoutTests/http/tests/inspector/console-test.js
@@ -33,7 +33,9 @@ InspectorTest.evaluateInConsoleAndDump = function(code, callback)
function mycallback(text)
{
- InspectorTest.addResult(code + " = " + text.replace(/\bVM\d+/g, "VM").replace(/InjectedScript\.\w+ @ VM:\d+/g, ""));
+ text = text.replace(/\bVM\d+/g, "VM");
+ text = text.replace(/(?:InjectedScript\.)?_?evaluate\w* @ VM:\d+/g, "");
+ InspectorTest.addResult(code + " = " + text);
callback(text);
}
InspectorTest.evaluateInConsole(code, mycallback);
@@ -45,7 +47,7 @@ InspectorTest.prepareConsoleMessageText = function(messageElement, consoleMessag
// Replace scriptIds with generic scriptId string to avoid flakiness.
messageText = messageText.replace(/VM\d+/g, "VM");
// Strip out InjectedScript line numbers from stack traces to avoid rebaselining each time InjectedScriptSource is edited.
- messageText = messageText.replace(/InjectedScript\.\w+ @ VM:\d+/g, "");
+ messageText = messageText.replace(/(?:InjectedScript\.)?_?evaluate\w* @ VM:\d+/g, "");
// Strip out InjectedScript line numbers from console message anchor.
var functionName = consoleMessage && consoleMessage.stackTrace && consoleMessage.stackTrace.callFrames[0] && consoleMessage.stackTrace.callFrames[0].functionName || "";
if (functionName.indexOf("InjectedScript") !== -1)
@@ -131,7 +133,7 @@ InspectorTest.formatterIgnoreStackFrameUrls = function(messageFormatter, node)
{
var buffer = string.replace(/\u200b/g, "");
buffer = buffer.replace(/VM\d+/g, "VM");
- buffer = buffer.replace(/InjectedScript\.\w+ @ VM:\d+/g, "");
+ buffer = buffer.replace(/(?:InjectedScript\.)?_?evaluate\w* @ VM:\d+/g, "");
return buffer.replace(/^\s+at [^\]]+(]?)$/, "$1");
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698