mirror of
https://github.com/LukeHagar/vercel.git
synced 2025-12-09 21:07:46 +00:00
Update to run Next.js integration with Node.js v18 (#10740)
Co-authored-by: Chris Barber <chris.barber@vercel.com> Co-authored-by: Steven <steven@ceriously.com>
This commit is contained in:
12
utils/chunk-tests.js
vendored
12
utils/chunk-tests.js
vendored
@@ -12,7 +12,14 @@ const runnersMap = new Map([
|
||||
},
|
||||
],
|
||||
['test-e2e', { min: 1, max: 7, runners: ['ubuntu-latest'] }],
|
||||
['test-next-local', { min: 1, max: 5, runners: ['ubuntu-latest'] }],
|
||||
[
|
||||
'test-next-local',
|
||||
{ min: 1, max: 5, runners: ['ubuntu-latest'], nodeVersion: '18' },
|
||||
],
|
||||
[
|
||||
'test-next-local-legacy',
|
||||
{ min: 1, max: 5, runners: ['ubuntu-latest'], nodeVersion: '16' },
|
||||
],
|
||||
['test-dev', { min: 1, max: 7, runners: ['ubuntu-latest', 'macos-latest'] }],
|
||||
]);
|
||||
|
||||
@@ -91,7 +98,7 @@ async function getChunkedTests() {
|
||||
const [packagePath, packageName] = packagePathAndName.split(',');
|
||||
return Object.entries(scriptNames).flatMap(([scriptName, testPaths]) => {
|
||||
const runnerOptions = getRunnerOptions(scriptName, packageName);
|
||||
const { runners, min, max } = runnerOptions;
|
||||
const { runners, min, max, nodeVersion } = runnerOptions;
|
||||
|
||||
const sortedTestPaths = testPaths.sort((a, b) => a.localeCompare(b));
|
||||
return intoChunks(min, max, sortedTestPaths).flatMap(
|
||||
@@ -102,6 +109,7 @@ async function getChunkedTests() {
|
||||
packagePath,
|
||||
packageName,
|
||||
scriptName,
|
||||
nodeVersion,
|
||||
testPaths: chunk.map(testFile =>
|
||||
path.relative(
|
||||
path.join(__dirname, '../', packagePath),
|
||||
|
||||
Reference in New Issue
Block a user