debug integration tests: make sure to focus editor before toggleBreakpoint

fixes #90047
This commit is contained in:
isidor
2020-02-05 10:49:16 +01:00
parent f69165d0c1
commit 1e057b7393

View File

@@ -41,13 +41,13 @@ suite('Debug', function () {
const file = await createRandomFile('let i = 5;', undefined, '.js');
const doc = await workspace.openTextDocument(file);
await window.showTextDocument(doc, undefined, false);
const breakpointsChanged = new Promise<void>(resolve => onBreakpointsChange = resolve);
await commands.executeCommand('editor.debug.action.toggleBreakpoint');
await breakpointsChanged;
assert.equal(debug.breakpoints.length, 1);
assert.equal(debug.breakpoints[0].enabled, true);
await window.showTextDocument(doc, undefined, false);
const breakpointsChangedSecond = new Promise<void>(resolve => onBreakpointsChange = resolve);
await commands.executeCommand('editor.debug.action.toggleBreakpoint');
await breakpointsChangedSecond;