| 173 | } |
| 174 | |
| 175 | async function runAtCursor( |
| 176 | uri: vscode.Uri, |
| 177 | position: CodeLensPosition, |
| 178 | ): Promise<void> { |
| 179 | const document = await vscode.workspace.openTextDocument(uri); |
| 180 | const editor = await vscode.window.showTextDocument(document, { |
| 181 | preview: false, |
| 182 | }); |
| 183 | const cursor = new vscode.Position(position.line, position.character); |
| 184 | editor.selection = new vscode.Selection(cursor, cursor); |
| 185 | editor.revealRange(new vscode.Range(cursor, cursor)); |
| 186 | await vscode.commands.executeCommand('testing.runAtCursor'); |
| 187 | } |
| 188 | |
| 189 | async function executeProcessTask( |
| 190 | uri: vscode.Uri, |