From 724208298337ccd884476ec5b6edc6f0244aa303 Mon Sep 17 00:00:00 2001 From: Alexandru Dima Date: Wed, 30 Dec 2020 21:49:51 +0100 Subject: [PATCH] Fixes #112834: Ensure the markdown link provider is registered before invoking `vscode.executeLinkProvider` --- .../markdown-language-features/src/test/documentLink.test.ts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/extensions/markdown-language-features/src/test/documentLink.test.ts b/extensions/markdown-language-features/src/test/documentLink.test.ts index 9b26d995f27..052610515a5 100644 --- a/extensions/markdown-language-features/src/test/documentLink.test.ts +++ b/extensions/markdown-language-features/src/test/documentLink.test.ts @@ -20,6 +20,11 @@ async function getLinksForFile(file: vscode.Uri): Promise suite('Markdown Document links', () => { + setup(async () => { + // the tests make the assumption that link providers are already registered + await vscode.extensions.getExtension('vscode.markdown-language-features')!.activate(); + }); + teardown(async () => { await vscode.commands.executeCommand('workbench.action.closeAllEditors'); });