Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/microsoft/vscode.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'extensions/markdown-language-features/src/test/util.ts')
-rw-r--r--extensions/markdown-language-features/src/test/util.ts17
1 files changed, 0 insertions, 17 deletions
diff --git a/extensions/markdown-language-features/src/test/util.ts b/extensions/markdown-language-features/src/test/util.ts
index b9dc2241090..220e79e2f60 100644
--- a/extensions/markdown-language-features/src/test/util.ts
+++ b/extensions/markdown-language-features/src/test/util.ts
@@ -6,28 +6,11 @@ import * as assert from 'assert';
import * as os from 'os';
import * as vscode from 'vscode';
import { DisposableStore } from '../util/dispose';
-import { InMemoryDocument } from '../util/inMemoryDocument';
export const joinLines = (...args: string[]) =>
args.join(os.platform() === 'win32' ? '\r\n' : '\n');
-export const CURSOR = '$$CURSOR$$';
-
-export function getCursorPositions(contents: string, doc: InMemoryDocument): vscode.Position[] {
- const positions: vscode.Position[] = [];
- let index = 0;
- let wordLength = 0;
- while (index !== -1) {
- index = contents.indexOf(CURSOR, index + wordLength);
- if (index !== -1) {
- positions.push(doc.positionAt(index));
- }
- wordLength = CURSOR.length;
- }
- return positions;
-}
-
export function workspacePath(...segments: string[]): vscode.Uri {
return vscode.Uri.joinPath(vscode.workspace.workspaceFolders![0].uri, ...segments);
}