remote_runner: Don't break long lines

Breaking lines makes it harder to read and search the test output.
This commit is contained in:
Richard Hansen 2021-05-02 20:31:25 -04:00
parent 7d75e0ef8f
commit 713e57b451

View file

@ -102,12 +102,8 @@ $(() => {
const $console = $('#console');
const append = (text) => {
const lines = text.split('\n')
// Break long lines into multiple lines:
.map((line) => line.match(/.{1,100}/g))
.reduce((soFar, next) => soFar.concat(next), [])
// Indent each line:
.map((line) => ' '.repeat(level * 2) + line);
// Indent each line.
const lines = text.split('\n').map((line) => ' '.repeat(level * 2) + line);
$console.append(document.createTextNode(`${lines.join('\\n')}\\n`));
};