mirror of
https://github.com/Microsoft/vscode
synced 2024-10-05 19:02:54 +00:00
tests - log the actual build used for tests
This commit is contained in:
parent
798a33f9c6
commit
869929e8c6
|
@ -86,8 +86,6 @@ function timeout(ms: number): Promise<void> {
|
|||
return new Promise<void>(r => setTimeout(r, ms));
|
||||
}
|
||||
|
||||
// function runInDriver(call: string, args: (string | boolean)[]): Promise<any> {}
|
||||
|
||||
let server: ChildProcess | undefined;
|
||||
let endpoint: string | undefined;
|
||||
let workspacePath: string | undefined;
|
||||
|
@ -105,8 +103,10 @@ export async function launch(userDataDir: string, _workspacePath: string, codeSe
|
|||
let serverLocation: string | undefined;
|
||||
if (codeServerPath) {
|
||||
serverLocation = join(codeServerPath, `server.${process.platform === 'win32' ? 'cmd' : 'sh'}`);
|
||||
console.log(`Starting built server from '${serverLocation}'`);
|
||||
} else {
|
||||
serverLocation = join(__dirname, '..', '..', '..', `resources/server/web.${process.platform === 'win32' ? 'bat' : 'sh'}`);
|
||||
console.log(`Starting server out of sources from '${serverLocation}'`);
|
||||
}
|
||||
server = spawn(
|
||||
serverLocation,
|
||||
|
|
|
@ -95,10 +95,13 @@ async function launchServer(): Promise<{ endpoint: url.UrlWithStringQuery, serve
|
|||
let serverLocation: string;
|
||||
if (process.env.VSCODE_REMOTE_SERVER_PATH) {
|
||||
serverLocation = path.join(process.env.VSCODE_REMOTE_SERVER_PATH, `server.${process.platform === 'win32' ? 'cmd' : 'sh'}`);
|
||||
|
||||
console.log(`Starting built server from '${serverLocation}'`);
|
||||
} else {
|
||||
serverLocation = path.join(__dirname, '..', '..', '..', '..', `resources/server/web.${process.platform === 'win32' ? 'bat' : 'sh'}`);
|
||||
|
||||
process.env.VSCODE_DEV = '1';
|
||||
|
||||
console.log(`Starting server out of sources from '${serverLocation}'`);
|
||||
}
|
||||
|
||||
let serverProcess = cp.spawn(
|
||||
|
|
|
@ -154,6 +154,8 @@ if (!opts.web) {
|
|||
} else {
|
||||
quality = Quality.Stable;
|
||||
}
|
||||
|
||||
console.log(`Running desktop smoke tests against ${electronPath}`);
|
||||
}
|
||||
|
||||
//
|
||||
|
@ -162,14 +164,20 @@ if (!opts.web) {
|
|||
else {
|
||||
const testCodeServerPath = opts.build || process.env.VSCODE_REMOTE_SERVER_PATH;
|
||||
|
||||
if (typeof testCodeServerPath === 'string' && !fs.existsSync(testCodeServerPath)) {
|
||||
fail(`Can't find Code server at ${testCodeServerPath}.`);
|
||||
if (typeof testCodeServerPath === 'string') {
|
||||
if (!fs.existsSync(testCodeServerPath)) {
|
||||
fail(`Can't find Code server at ${testCodeServerPath}.`);
|
||||
} else {
|
||||
console.log(`Running web smoke tests against ${testCodeServerPath}`);
|
||||
}
|
||||
}
|
||||
|
||||
if (!testCodeServerPath) {
|
||||
process.env.VSCODE_REPOSITORY = repoPath;
|
||||
process.env.VSCODE_DEV = '1';
|
||||
process.env.VSCODE_CLI = '1';
|
||||
|
||||
console.log(`Running web smoke out of sources`);
|
||||
}
|
||||
|
||||
if (process.env.VSCODE_DEV === '1') {
|
||||
|
|
Loading…
Reference in a new issue