mirror of
https://github.com/microsoft/vscode.git
synced 2026-04-28 12:33:35 +01:00
avoid conflict with jupyter in OSS
This commit is contained in:
@@ -23,8 +23,8 @@ function waitFor(ms: number): Promise<void> {
|
||||
|
||||
suite('notebook workflow', () => {
|
||||
test('notebook open', async function () {
|
||||
const resource = vscode.Uri.parse(join(vscode.workspace.rootPath || '', './first.ipynb'));
|
||||
await vscode.commands.executeCommand('vscode.openWith', resource, 'notebookTest');
|
||||
const resource = vscode.Uri.parse(join(vscode.workspace.rootPath || '', './first.vsctestnb'));
|
||||
await vscode.commands.executeCommand('vscode.openWith', resource, 'notebookCoreTest');
|
||||
|
||||
await waitFor(500);
|
||||
assert.equal(vscode.notebook.activeNotebookEditor !== undefined, true, 'notebook first');
|
||||
@@ -46,8 +46,8 @@ suite('notebook workflow', () => {
|
||||
});
|
||||
|
||||
test('notebook cell actions', async function () {
|
||||
const resource = vscode.Uri.parse(join(vscode.workspace.rootPath || '', './second.ipynb'));
|
||||
await vscode.commands.executeCommand('vscode.openWith', resource, 'notebookTest');
|
||||
const resource = vscode.Uri.parse(join(vscode.workspace.rootPath || '', './second.vsctestnb'));
|
||||
await vscode.commands.executeCommand('vscode.openWith', resource, 'notebookCoreTest');
|
||||
|
||||
await waitFor(500);
|
||||
assert.equal(vscode.notebook.activeNotebookEditor !== undefined, true, 'notebook first');
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
import * as vscode from 'vscode';
|
||||
|
||||
export function activate(context: vscode.ExtensionContext): any {
|
||||
context.subscriptions.push(vscode.notebook.registerNotebookProvider('notebookTest', {
|
||||
context.subscriptions.push(vscode.notebook.registerNotebookProvider('notebookCoreTest', {
|
||||
resolveNotebook: async (editor: vscode.NotebookEditor) => {
|
||||
await editor.edit(eb => {
|
||||
eb.insert(0, 'test', 'typescript', vscode.CellKind.Code, [], {});
|
||||
|
||||
Reference in New Issue
Block a user