Skip to content

Commit f13e06a

Browse files
fossamagnajuanarbol
authored andcommitted
test: improve lib/readline.js coverage
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]>
1 parent 891c4e7 commit f13e06a

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

‎test/parallel/test-readline-interface.js‎

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,19 @@ function assertCursorRowsAndCols(rli, rows, cols){
7171
assert(rlinstanceofreadline.Interface);
7272
}
7373

74+
{
75+
constfi=newFakeInput();
76+
constrli=newreadline.Interface(
77+
fi,
78+
fi,
79+
common.mustCall((line)=>[[],line]),
80+
true,
81+
);
82+
assert(rliinstanceofreadline.Interface);
83+
fi.emit('data','a\t');
84+
rli.close();
85+
}
86+
7487
[
7588
undefined,
7689
50,

0 commit comments

Comments
(0)