From dfb4dbe9618df37c77bc8c93de9e892a30b23ec6 Mon Sep 17 00:00:00 2001 From: rebornix Date: Wed, 20 May 2020 16:22:09 -0700 Subject: [PATCH] restore notebook state after test. --- extensions/vscode-notebook-tests/src/notebook.test.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/extensions/vscode-notebook-tests/src/notebook.test.ts b/extensions/vscode-notebook-tests/src/notebook.test.ts index 8f0092ba51c..19d9e97a2c4 100644 --- a/extensions/vscode-notebook-tests/src/notebook.test.ts +++ b/extensions/vscode-notebook-tests/src/notebook.test.ts @@ -347,6 +347,9 @@ suite('notebook workflow', () => { const newActiveCell = vscode.notebook.activeNotebookEditor!.selection; assert.deepEqual(activeCell, newActiveCell); + await vscode.commands.executeCommand('workbench.action.files.saveAll'); + await vscode.commands.executeCommand('workbench.action.closeAllEditors'); + // TODO@rebornix, there are still some events order issue. // assert.equal(vscode.notebook.activeNotebookEditor!.document.cells.indexOf(newActiveCell!), 2); });