Skip to content

Commit

Permalink
Add Vercel E2E tests back
Browse files Browse the repository at this point in the history
  • Loading branch information
ardatan committed Jan 3, 2025
1 parent 9bbaf1f commit 1673611
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 9 deletions.
5 changes: 5 additions & 0 deletions .changeset/sixty-rings-dress.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@whatwg-node/server': patch
---

Fixes for Next.js
3 changes: 1 addition & 2 deletions .github/workflows/deployment-e2e.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,7 @@ jobs:
strategy:
fail-fast: false
matrix:
plan: ['aws-lambda', 'azure-function', 'cloudflare-workers', 'cloudflare-modules', 'deno']
# TODO: Add vercel
plan: ['aws-lambda', 'azure-function', 'cloudflare-workers', 'cloudflare-modules', 'deno', 'vercel']
name: e2e / ${{ matrix.plan }}

runs-on: ubuntu-latest
Expand Down
2 changes: 1 addition & 1 deletion e2e/vercel/scripts/bundle.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ const { build } = require('esbuild');
async function main() {
await build({
entryPoints: ['./src/index.ts'],
outfile: 'pages/api/whatwgnode.js',
outfile: 'pages/api/[...slug].js',
format: 'cjs',
minify: false,
bundle: true,
Expand Down
9 changes: 3 additions & 6 deletions e2e/vercel/scripts/createVercelDeployment.ts
Original file line number Diff line number Diff line change
Expand Up @@ -133,16 +133,13 @@ export function createVercelDeployment(): DeploymentConfiguration<{
const deployment = new VercelDeployment('vercel-function', {
files: [
{
file: '/api/whatwgnode.js',
data: await fsPromises.readFile(
join(__dirname, '..', 'pages', 'api', 'whatwgnode.js'),
'utf-8',
),
file: '/api/[...slug].js',
data: await fsPromises.readFile(join(__dirname, '..', 'pages', 'api', '[...slug].js'), 'utf-8'),
},
],
name: `whatwg-node-e2e-testing`,
functions: {
'api/whatwgnode.js': {
'api/[...slug].js': {
memory: 256,
maxDuration: 5,
},
Expand Down

0 comments on commit 1673611

Please sign in to comment.