[tests] Pass in builder to runBuildLambda() (#9262)

Removes the need for `next`/`static-build` to be present in the root `package.json` file.
This commit is contained in:
Nathan Rajlich
2023-01-19 15:10:06 -08:00
committed by GitHub
parent cc687b3880
commit a7a5bf1a12
7 changed files with 64 additions and 85 deletions

View File

@@ -6,10 +6,13 @@ import type { Context } from '../types';
import { duplicateWithConfig } from '../utils';
import fs from 'fs-extra';
import path from 'path';
import runBuildLambda from '../../../../test/lib/run-build-lambda';
import * as builder from '../../';
import { createRunBuildLambda } from '../../../../test/lib/run-build-lambda';
import { EdgeFunction, Files, streamToBuffer } from '@vercel/build-utils';
import { createHash } from 'crypto';
const runBuildLambda = createRunBuildLambda(builder);
const SIMPLE_PROJECT = path.resolve(
__dirname,
'..',