提交 7a21839e 编写于 作者: D Daniel Imms

Add test for onDidChangeActiveTerminal

上级 0a372aaf
......@@ -583,5 +583,20 @@ suite('window namespace tests', () => {
});
const renderer = window.createTerminalRenderer('foo');
});
test('onDidChangeActiveTerminal should fire when new terminals are created', (done) => {
const reg1 = window.onDidChangeActiveTerminal((active: Terminal | undefined) => {
assert.equal(active, terminal);
reg1.dispose();
const reg2 = window.onDidChangeActiveTerminal((active: Terminal | undefined) => {
assert.equal(active, undefined);
reg2.dispose();
done();
});
terminal.dispose();
});
const terminal = window.createTerminal();
terminal.show();
});
});
});
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册