Convert scroll to EventEmitter2
This commit is contained in:
+16
-2
@@ -90,7 +90,6 @@ describe('xterm.js', () => {
|
||||
term.on('cursormove', () => {
|
||||
done();
|
||||
});
|
||||
|
||||
term.write('foo');
|
||||
});
|
||||
});
|
||||
@@ -100,11 +99,26 @@ describe('xterm.js', () => {
|
||||
term.on('linefeed', () => {
|
||||
done();
|
||||
});
|
||||
|
||||
term.write('\n');
|
||||
});
|
||||
});
|
||||
|
||||
describe('scroll', () => {
|
||||
it('should emit a scroll event when scrollback is created', (done) => {
|
||||
term.on('scroll', () => {
|
||||
done();
|
||||
});
|
||||
term.write('\n'.repeat(INIT_ROWS));
|
||||
});
|
||||
it('should emit a scroll event when scrollback is cleared', (done) => {
|
||||
term.write('\n'.repeat(INIT_ROWS));
|
||||
term.on('scroll', () => {
|
||||
done();
|
||||
});
|
||||
term.clear();
|
||||
});
|
||||
});
|
||||
|
||||
describe(`keypress (including 'key' event)`, () => {
|
||||
it('should receive a string and event object', (done) => {
|
||||
let steps = 0;
|
||||
|
||||
Reference in New Issue
Block a user