Skip to content

Commit

Permalink
build: run e2e tests in production mode
Browse files Browse the repository at this point in the history
This is more similar to the production environment, which is probably
nice to have.

Related to #83
  • Loading branch information
JoosepAlviste committed Dec 31, 2023
1 parent 6f25b13 commit 6b9cd9d
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 5 deletions.
2 changes: 1 addition & 1 deletion apps/api/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
"build": "NODE_ENV=production rimraf dist && tsx bin/build.ts && resolve-tspaths",
"start": "NODE_ENV=development tsx watch --clear-screen=false src/main.ts",
"start:prod": "NODE_ENV=production node dist/main.js",
"start:e2e": "dotenv -e ../../.env.e2e -v NODE_ENV=test tsx watch src/main.ts",
"start:e2e": "dotenv -e ../../.env.e2e -v NODE_ENV=test pnpm build && pnpm start:prod",
"start:tmdb": "tsx watch src/test/mockTMDBServer.ts",
"start:jobs": "NODE_ENV=development tsx watch --clear-screen=false src/mainJobs.ts",
"start:jobs:prod": "NODE_ENV=production node dist/mainJobs.js",
Expand Down
2 changes: 1 addition & 1 deletion apps/e2e/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"version": "1.0.0",
"type": "module",
"scripts": {
"test:e2e": "dotenv -e ../../.env.e2e pnpm exec playwright test -- --ui",
"test:e2e": "dotenv -e ../../.env.e2e pnpm exec playwright test",
"test:e2e:headed": "pnpm test:e2e -- --headed"
},
"devDependencies": {
Expand Down
3 changes: 1 addition & 2 deletions apps/e2e/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
{
"extends": "@serieslist/typescript-config-base",
"compilerOptions": {}
"extends": "@serieslist/typescript-config-base"
}
2 changes: 1 addition & 1 deletion apps/webapp/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"type": "module",
"scripts": {
"start": "tsx ./src/server/server.ts",
"start:e2e": "dotenv -e ../../.env.e2e pnpm start",
"start:e2e": "dotenv -e ../../.env.e2e pnpm build && pnpm start:prod",
"build": "rimraf dist && vite build && pnpm build:server",
"build:server": "tsx bin/build.ts && resolve-tspaths --out dist/prodServer",
"start:prod": "cross-env NODE_ENV=production node dist/prodServer/server.js",
Expand Down

0 comments on commit 6b9cd9d

Please sign in to comment.