Merge from vscode 8aa90d444f5d051984e8055f547c4252d53479b3 (#5587)

* Merge from vscode 8aa90d444f5d051984e8055f547c4252d53479b3

* pipeline errors

* fix build
This commit is contained in:
Anthony Dresser
2019-05-23 11:16:03 -07:00
committed by GitHub
parent ca36f20c6b
commit cf8f8907ee
141 changed files with 6450 additions and 1228 deletions

View File

@@ -6,9 +6,11 @@
import * as path from 'path';
import * as cp from 'child_process';
import * as os from 'os';
import * as fs from 'fs';
import { tmpName } from 'tmp';
import { IDriver, connect as connectDriver, IDisposable, IElement, Thenable } from './driver';
import { Logger } from '../logger';
import { ncp } from 'ncp';
const repoPath = path.join(__dirname, '../../../..');
@@ -128,6 +130,15 @@ export async function spawn(options: SpawnOptions): Promise<Code> {
`--${options.workspacePath.endsWith('.code-workspace') ? 'file' : 'folder'}-uri`,
`vscode-remote://test+test${options.workspacePath}`,
);
if (codePath) {
// running against a build: copy the test resolver extension
const testResolverExtPath = path.join(options.extensionsPath, 'vscode-test-resolver');
if (!fs.existsSync(testResolverExtPath)) {
const orig = path.join(repoPath, 'extensions', 'vscode-test-resolver');
await new Promise((c, e) => ncp(orig, testResolverExtPath, err => err ? e(err) : c()));
}
}
args.push('--enable-proposed-api=vscode.vscode-test-resolver');
}
if (!codePath) {