From 68b041c4fb96e036b28ca6d891b77926ba61128b Mon Sep 17 00:00:00 2001 From: Richard Hansen Date: Sun, 2 May 2021 20:46:00 -0400 Subject: [PATCH] remote_runner: Use newline instead of backslash n --- src/tests/frontend/runner.js | 2 +- src/tests/frontend/travis/remote_runner.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/tests/frontend/runner.js b/src/tests/frontend/runner.js index c405b79ee..7389c13ee 100644 --- a/src/tests/frontend/runner.js +++ b/src/tests/frontend/runner.js @@ -104,7 +104,7 @@ $(() => { const append = (text) => { // Indent each line. const lines = text.split('\n').map((line) => ' '.repeat(level * 2) + line); - $console.append(document.createTextNode(`${lines.join('\\n')}\\n`)); + $console.append(document.createTextNode(`${lines.join('\n')}\n`)); }; const total = runner.total; diff --git a/src/tests/frontend/travis/remote_runner.js b/src/tests/frontend/travis/remote_runner.js index 67330b19b..bbb41addb 100644 --- a/src/tests/frontend/travis/remote_runner.js +++ b/src/tests/frontend/travis/remote_runner.js @@ -53,7 +53,7 @@ const sauceTestWorker = async.queue(async (testSettings) => { let logIndex = 0; while (true) { const consoleText = await browser.eval("$('#console').text()") || ''; - consoleText.substring(logIndex).split('\\n').forEach((line) => log(line, pfx)); + consoleText.substring(logIndex).split('\n').forEach((line) => log(line, pfx)); logIndex = consoleText.length; const [finished, nFailedStr] = consoleText.match(finishedRegex) || []; if (finished) {