Skip to content

Commit

Permalink
test: improve lib/readline.js coverage
Browse files Browse the repository at this point in the history
PR-URL: #42686
Refs: https://coverage.nodejs.org/coverage-a0461255c05c79cf/lib/readline.js.html#L105
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: James M Snell <[email protected]>
Reviewed-By: Moshe Atlow <[email protected]>
  • Loading branch information
fossamagna authored and RafaelGSS committed Sep 26, 2022
1 parent 7ffc037 commit fcfdb6c
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions test/parallel/test-readline-interface.js
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,19 @@ function assertCursorRowsAndCols(rli, rows, cols) {
assert(rl instanceof readline.Interface);
}

{
const fi = new FakeInput();
const rli = new readline.Interface(
fi,
fi,
common.mustCall((line) => [[], line]),
true,
);
assert(rli instanceof readline.Interface);
fi.emit('data', 'a\t');
rli.close();
}

[
undefined,
50,
Expand Down

0 comments on commit fcfdb6c

Please sign in to comment.