diff --git a/.github/workflows/test-e2e.yml b/.github/workflows/test-e2e.yml index 29975aeaef..af388ee528 100644 --- a/.github/workflows/test-e2e.yml +++ b/.github/workflows/test-e2e.yml @@ -150,7 +150,7 @@ jobs: - name: patch Next.js run: | cp ../${{ env.runtime-path }}/tests/netlify-deploy.ts test/lib/next-modes/ - git apply ../${{ env.runtime-path }}/tests/e2e-utils.patch + git apply ../${{ env.runtime-path }}/tests/e2e-utils.patch || git apply ../${{ env.runtime-path }}/tests/e2e-utils-v2.patch working-directory: ${{ env.next-path }} - name: install Next.js diff --git a/run-local-test.sh b/run-local-test.sh index 4e61cf057b..4cfa139e8c 100755 --- a/run-local-test.sh +++ b/run-local-test.sh @@ -15,7 +15,7 @@ export NEXT_TEST_MODE=deploy export RUNTIME_DIR=$(pwd) cp tests/netlify-deploy.ts ../next.js/test/lib/next-modes/netlify-deploy.ts cd ../next.js/ -git apply ../next-runtime/tests/e2e-utils.patch +git apply ../next-runtime/tests/e2e-utils.patch || git apply ../next-runtime/tests/e2e-utils-v2.patch node run-tests.js --type e2e --debug --test-pattern $1 git checkout -- test/lib/e2e-utils.ts diff --git a/tests/e2e-utils-v2.patch b/tests/e2e-utils-v2.patch new file mode 100644 index 0000000000..65f118e33f --- /dev/null +++ b/tests/e2e-utils-v2.patch @@ -0,0 +1,13 @@ +diff --git a/test/lib/e2e-utils/index.ts b/test/lib/e2e-utils/index.ts +index 06765e81d9..a7a5a9e4bd 100644 +--- a/test/lib/e2e-utils/index.ts ++++ b/test/lib/e2e-utils/index.ts +@@ -5,7 +5,7 @@ import { PHASE_DEVELOPMENT_SERVER } from 'next/constants' + import { NextInstance, NextInstanceOpts } from '../next-modes/base' + import { NextDevInstance } from '../next-modes/next-dev' + import { NextStartInstance } from '../next-modes/next-start' +-import { NextDeployInstance } from '../next-modes/next-deploy' ++import { NextDeployInstance } from '../next-modes/netlify-deploy' + import { shouldRunTurboDevTest } from '../next-test-utils' + + export type { NextInstance }