File tree Expand file tree Collapse file tree 3 files changed +8
-4
lines changed Expand file tree Collapse file tree 3 files changed +8
-4
lines changed Original file line number Diff line number Diff line change 11/** @type {import('next').NextConfig } */
2+ const isE2E = process . env . PLAYWRIGHT_TEST === '1'
23const nextConfig = {
34 basePath : process . env . PAGES_BASE_PATH ,
45 distDir : 'out' ,
@@ -8,7 +9,7 @@ const nextConfig = {
89 images : {
910 unoptimized : true ,
1011 } ,
11- output : 'export' ,
12+ output : isE2E ? undefined : 'export' ,
1213 reactStrictMode : true ,
1314 trailingSlash : false ,
1415} ;
Original file line number Diff line number Diff line change 1111 "test:ui" : " vitest --ui" ,
1212 "test:ci" : " vitest --run" ,
1313 "test:coverage" : " vitest --coverage" ,
14- "test:e2e" : " playwright test" ,
15- "test:e2e:ui" : " playwright test --ui" ,
16- "test:e2e:headed" : " playwright test --headed" ,
14+ "test:e2e" : " PLAYWRIGHT_TEST=1 playwright test" ,
15+ "test:e2e:ui" : " PLAYWRIGHT_TEST=1 playwright test --ui" ,
16+ "test:e2e:headed" : " PLAYWRIGHT_TEST=1 playwright test --headed" ,
1717 "fetch:versions" : " npx tsx scripts/fetch-versions.ts" ,
1818 "fetch:downloads" : " npx tsx scripts/fetch-downloads.ts" ,
1919 "update:data" : " npm run fetch:versions && npm run fetch:downloads"
Original file line number Diff line number Diff line change @@ -24,5 +24,8 @@ export default defineConfig({
2424 url : 'http://localhost:3000' ,
2525 reuseExistingServer : ! process . env . CI ,
2626 timeout : 120000 ,
27+ env : {
28+ PLAYWRIGHT_TEST : '1' ,
29+ } ,
2730 } ,
2831} ) ;
You can’t perform that action at this time.
0 commit comments