Fix bug with process.stdout.clearLine being missing. Use readline instead.
continuous-integration/appveyor/branch AppVeyor build succeeded Details

master v1.3.0
Jonatan Nilsson 2022-01-11 09:43:48 +00:00
parent 26217cd529
commit 819ca84429
1 changed files with 3 additions and 2 deletions

View File

@ -1,3 +1,4 @@
import * as readline from 'readline'
import { printError } from './cli.mjs'
function Group(e, name) {
@ -235,8 +236,8 @@ Eltro.prototype.__runTest = async function(stats, test, prefix = 'Test', child =
}
if (this.reporter === 'list') {
process.stdout.clearLine();
process.stdout.cursorTo(0);
readline.clearLine(process.stdout, 0)
readline.cursorTo(process.stdout, 0, null)
if (markRealTest.skipTest) {
process.stdout.write(' \x1b[94m- ' + markRealTest.name + '\x1b[0m\n')
} else if (!markRealTest.error) {