chore: bump node to v16.5.0 (main) (#30031)

* chore: bump node in DEPS to v16.4.2

* chore: update patches

* ci: run main and remote woa tests separately

* chore: bump node in DEPS to v16.5.0

* build: restore libplatform headers in distribution

https://github.com/nodejs/node/pull/39288

* build: pass directory instead of list of files to js2c.py

https://github.com/nodejs/node/pull/39069

* chore: various BoringSSL/OpenSSL upstreams

- https://github.com/nodejs/node/pull/39136
- https://github.com/nodejs/node/pull/39138
- https://github.com/nodejs/node/pull/39054

* test: move debugger test case to parallel

https://github.com/nodejs/node/pull/39300

* chore: fixup patch indices

* build: pass directory instead of list of files to js2c.py

https://github.com/nodejs/node/pull/39069

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: PatchUp <73610968+patchup[bot]@users.noreply.github.com>
Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
This commit is contained in:
electron-roller[bot] 2021-07-15 11:25:00 -04:00 committed by GitHub
parent 849a3b6f81
commit 063ac19712
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
18 changed files with 378 additions and 372 deletions

View file

@ -13,7 +13,7 @@ const fail = '✗'.red;
const args = require('minimist')(process.argv, {
string: ['runners', 'target'],
boolean: ['buildNativeTests'],
boolean: ['buildNativeTests', 'runTestFilesSeperately'],
unknown: arg => unknownFlags.push(arg)
});
@ -123,24 +123,55 @@ async function runElectronTests () {
}
}
async function runRemoteBasedElectronTests () {
async function runTestUsingElectron (specDir, testName) {
let exe = path.resolve(BASE, utils.getElectronExec());
const runnerArgs = ['electron/spec', ...unknownArgs.slice(2)];
const runnerArgs = [`electron/${specDir}`, ...unknownArgs.slice(2)];
if (process.platform === 'linux') {
runnerArgs.unshift(path.resolve(__dirname, 'dbus_mock.py'), exe);
exe = 'python3';
}
const { status } = childProcess.spawnSync(exe, runnerArgs, {
const { status, signal } = childProcess.spawnSync(exe, runnerArgs, {
cwd: path.resolve(__dirname, '../..'),
stdio: 'inherit'
});
if (status !== 0) {
const textStatus = process.platform === 'win32' ? `0x${status.toString(16)}` : status.toString();
console.log(`${fail} Electron tests failed with code ${textStatus}.`);
if (status) {
const textStatus = process.platform === 'win32' ? `0x${status.toString(16)}` : status.toString();
console.log(`${fail} Electron tests failed with code ${textStatus}.`);
} else {
console.log(`${fail} Electron tests failed with kill signal ${signal}.`);
}
process.exit(1);
}
console.log(`${pass} Electron remote process tests passed.`);
console.log(`${pass} Electron ${testName} process tests passed.`);
}
const specFilter = (file) => {
if (!/-spec\.[tj]s$/.test(file)) {
return false;
} else {
return true;
}
};
async function runTests (specDir, testName) {
if (args.runTestFilesSeperately) {
const getFiles = require('../spec/static/get-files');
const testFiles = await getFiles(path.resolve(__dirname, `../${specDir}`), { filter: specFilter });
const baseElectronDir = path.resolve(__dirname, '..');
unknownArgs.splice(unknownArgs.length, 0, '--files', '');
testFiles.sort().forEach(async (file) => {
unknownArgs.splice((unknownArgs.length - 1), 1, path.relative(baseElectronDir, file));
console.log(`Running tests for ${unknownArgs[unknownArgs.length - 1]}`);
await runTestUsingElectron(specDir, testName);
});
} else {
await runTestUsingElectron(specDir, testName);
}
}
async function runRemoteBasedElectronTests () {
await runTests('spec', 'remote');
}
async function runNativeElectronTests () {
@ -195,27 +226,7 @@ async function runNativeElectronTests () {
}
async function runMainProcessElectronTests () {
let exe = path.resolve(BASE, utils.getElectronExec());
const runnerArgs = ['electron/spec-main', ...unknownArgs.slice(2)];
if (process.platform === 'linux') {
runnerArgs.unshift(path.resolve(__dirname, 'dbus_mock.py'), exe);
exe = 'python3';
}
const { status, signal } = childProcess.spawnSync(exe, runnerArgs, {
cwd: path.resolve(__dirname, '../..'),
stdio: 'inherit'
});
if (status !== 0) {
if (status) {
const textStatus = process.platform === 'win32' ? `0x${status.toString(16)}` : status.toString();
console.log(`${fail} Electron tests failed with code ${textStatus}.`);
} else {
console.log(`${fail} Electron tests failed with kill signal ${signal}.`);
}
process.exit(1);
}
console.log(`${pass} Electron main process tests passed.`);
await runTests('spec-main', 'main');
}
async function installSpecModules (dir) {