(target: Uri, contents: string, tempDir: TemporaryDirectory)
| 123 | } |
| 124 | |
| 125 | private async makeSourceFile(target: Uri, contents: string, tempDir: TemporaryDirectory): Promise<Uri> { |
| 126 | // Creates a temporary file with the same base name as the target file |
| 127 | const fileName = path.basename(target.fsPath, path.extname(target.fsPath)); |
| 128 | const sourceFilePath = await new ExportUtilNode().makeFileInDirectory( |
| 129 | contents, |
| 130 | `${fileName}.ipynb`, |
| 131 | tempDir.path |
| 132 | ); |
| 133 | return Uri.file(sourceFilePath); |
| 134 | } |
| 135 | |
| 136 | protected async getExecutionService( |
| 137 | source: Uri, |
no test coverage detected