Fix translateToString endCol default arg

This commit is contained in:
Daniel Imms
2018-12-18 16:22:41 -08:00
parent d27b43d515
commit 04ac36fc16
4 changed files with 13 additions and 10 deletions
+5
View File
@@ -325,5 +325,10 @@ describe('BufferLine', function(): void {
chai.expect(line.translateToString(false)).equal(' ');
chai.expect(line.translateToString(true)).equal('');
});
it('should work with endCol=0', () => {
const line = new TestBufferLine(10, [DEFAULT_ATTR, NULL_CELL_CHAR, 0, NULL_CELL_CODE], false);
line.set(0, [1, 'a', 1, 'a'.charCodeAt(0)]);
chai.expect(line.translateToString(true, 0, 0)).equal('');
});
});
});