mirror of
https://github.com/Microsoft/vscode
synced 2024-09-13 21:55:38 +00:00
re #102899.
This commit is contained in:
parent
1a2e3fa16c
commit
cf9d6d7667
|
@ -876,7 +876,6 @@ suite('regression', () => {
|
||||||
await vscode.commands.executeCommand('vscode.openWith', resource, 'default');
|
await vscode.commands.executeCommand('vscode.openWith', resource, 'default');
|
||||||
assert.equal(vscode.window.activeTextEditor?.document.uri.path, resource.path);
|
assert.equal(vscode.window.activeTextEditor?.document.uri.path, resource.path);
|
||||||
|
|
||||||
await vscode.commands.executeCommand('workbench.action.revertAndCloseActiveEditor');
|
|
||||||
await vscode.commands.executeCommand('workbench.action.closeAllEditors');
|
await vscode.commands.executeCommand('workbench.action.closeAllEditors');
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -884,9 +883,8 @@ suite('regression', () => {
|
||||||
test('#96105 - dirty editors', async function () {
|
test('#96105 - dirty editors', async function () {
|
||||||
const resource = vscode.Uri.file(join(vscode.workspace.rootPath || '', './empty.vsctestnb'));
|
const resource = vscode.Uri.file(join(vscode.workspace.rootPath || '', './empty.vsctestnb'));
|
||||||
await vscode.commands.executeCommand('vscode.openWith', resource, 'default');
|
await vscode.commands.executeCommand('vscode.openWith', resource, 'default');
|
||||||
await vscode.commands.executeCommand('notebook.cell.insertCodeCellBelow');
|
|
||||||
const edit = new vscode.WorkspaceEdit();
|
const edit = new vscode.WorkspaceEdit();
|
||||||
edit.insert(vscode.notebook.activeNotebookEditor!.selection!.uri, new vscode.Position(0, 0), 'var abc = 0;');
|
edit.insert(resource, new vscode.Position(0, 0), 'var abc = 0;');
|
||||||
await vscode.workspace.applyEdit(edit);
|
await vscode.workspace.applyEdit(edit);
|
||||||
|
|
||||||
// now it's dirty, open the resource with notebook editor should open a new one
|
// now it's dirty, open the resource with notebook editor should open a new one
|
||||||
|
@ -894,7 +892,6 @@ suite('regression', () => {
|
||||||
assert.notEqual(vscode.notebook.activeNotebookEditor, undefined, 'notebook first');
|
assert.notEqual(vscode.notebook.activeNotebookEditor, undefined, 'notebook first');
|
||||||
assert.notEqual(vscode.window.activeTextEditor, undefined);
|
assert.notEqual(vscode.window.activeTextEditor, undefined);
|
||||||
|
|
||||||
await vscode.commands.executeCommand('workbench.action.revertAndCloseActiveEditor');
|
|
||||||
await vscode.commands.executeCommand('workbench.action.closeAllEditors');
|
await vscode.commands.executeCommand('workbench.action.closeAllEditors');
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue