fix failing test cases

This commit is contained in:
Jörg Breitbart
2018-11-29 21:48:48 +01:00
parent eb27641928
commit 99e4a9649f
2 changed files with 14 additions and 19 deletions
+3 -2
View File
@@ -116,10 +116,11 @@ describe('search addon', () => {
expect(tilda2).eql({col: 0, row: 3, term: '~'});
});
it('should not select empty lines', () => {
// with addition of a real null char printing spaces is not considered empty anymore
search.apply(<any>MockTerminal);
const term = new MockTerminal({cols: 20, rows: 3});
term.core.write(' ');
term.pushWriteData();
// with addition of a null char printing spaces is not considered empty anymore
// therefore we write nothing here
const line = term.searchHelper.findInLine('^.*$', 0, { regex: true });
expect(line).eql(undefined);
});