chore(test): catalog @playwright/test and wire e2e into turbo
- Promote @playwright/test to the workspace catalog
- Add test:e2e turbo task (uncached)
- Add root pnpm test:e2e script
- Vitest scopes to src/**/*.{test,spec} and excludes e2e/
This commit is contained in:
@@ -8,6 +8,7 @@
|
|||||||
"build": "turbo run build",
|
"build": "turbo run build",
|
||||||
"lint": "turbo run lint",
|
"lint": "turbo run lint",
|
||||||
"test": "turbo run test",
|
"test": "turbo run test",
|
||||||
|
"test:e2e": "turbo run test:e2e",
|
||||||
"typecheck": "turbo run typecheck",
|
"typecheck": "turbo run typecheck",
|
||||||
"prepare": "husky"
|
"prepare": "husky"
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -43,7 +43,7 @@
|
|||||||
"zod": "catalog:"
|
"zod": "catalog:"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@playwright/test": "^1.59.1",
|
"@playwright/test": "catalog:",
|
||||||
"@tanstack/router-plugin": "^1.120.3",
|
"@tanstack/router-plugin": "^1.120.3",
|
||||||
"@testing-library/jest-dom": "catalog:",
|
"@testing-library/jest-dom": "catalog:",
|
||||||
"@testing-library/react": "catalog:",
|
"@testing-library/react": "catalog:",
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
import { defineConfig } from "vitest/config";
|
|
||||||
import react from "@vitejs/plugin-react";
|
|
||||||
import path from "node:path";
|
import path from "node:path";
|
||||||
import { fileURLToPath } from "node:url";
|
import { fileURLToPath } from "node:url";
|
||||||
|
import react from "@vitejs/plugin-react";
|
||||||
|
import { defineConfig } from "vitest/config";
|
||||||
|
|
||||||
const __dirname = path.dirname(fileURLToPath(import.meta.url));
|
const __dirname = path.dirname(fileURLToPath(import.meta.url));
|
||||||
|
|
||||||
@@ -20,5 +20,7 @@ export default defineConfig({
|
|||||||
globals: true,
|
globals: true,
|
||||||
setupFiles: ["./src/test/setup.ts"],
|
setupFiles: ["./src/test/setup.ts"],
|
||||||
css: false,
|
css: false,
|
||||||
|
include: ["src/**/*.{test,spec}.{ts,tsx}"],
|
||||||
|
exclude: ["node_modules", "dist", "e2e"],
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
|
|||||||
5
pnpm-lock.yaml
generated
5
pnpm-lock.yaml
generated
@@ -9,6 +9,9 @@ catalogs:
|
|||||||
'@biomejs/biome':
|
'@biomejs/biome':
|
||||||
specifier: ^2.4.0
|
specifier: ^2.4.0
|
||||||
version: 2.4.13
|
version: 2.4.13
|
||||||
|
'@playwright/test':
|
||||||
|
specifier: ^1.59.1
|
||||||
|
version: 1.59.1
|
||||||
'@testing-library/jest-dom':
|
'@testing-library/jest-dom':
|
||||||
specifier: ^6.6.3
|
specifier: ^6.6.3
|
||||||
version: 6.9.1
|
version: 6.9.1
|
||||||
@@ -193,7 +196,7 @@ importers:
|
|||||||
version: 4.3.6
|
version: 4.3.6
|
||||||
devDependencies:
|
devDependencies:
|
||||||
'@playwright/test':
|
'@playwright/test':
|
||||||
specifier: ^1.59.1
|
specifier: 'catalog:'
|
||||||
version: 1.59.1
|
version: 1.59.1
|
||||||
'@tanstack/router-plugin':
|
'@tanstack/router-plugin':
|
||||||
specifier: ^1.120.3
|
specifier: ^1.120.3
|
||||||
|
|||||||
@@ -8,6 +8,7 @@ catalog:
|
|||||||
"@biomejs/biome": "^2.4.0"
|
"@biomejs/biome": "^2.4.0"
|
||||||
|
|
||||||
# Testing
|
# Testing
|
||||||
|
"@playwright/test": "^1.59.1"
|
||||||
"@testing-library/jest-dom": "^6.6.3"
|
"@testing-library/jest-dom": "^6.6.3"
|
||||||
"@testing-library/react": "^16.3.0"
|
"@testing-library/react": "^16.3.0"
|
||||||
"@testing-library/user-event": "^14.6.1"
|
"@testing-library/user-event": "^14.6.1"
|
||||||
|
|||||||
@@ -15,6 +15,10 @@
|
|||||||
"test": {
|
"test": {
|
||||||
"inputs": ["src/**", "vitest.config.*", "package.json"]
|
"inputs": ["src/**", "vitest.config.*", "package.json"]
|
||||||
},
|
},
|
||||||
|
"test:e2e": {
|
||||||
|
"cache": false,
|
||||||
|
"inputs": ["e2e/**", "src/**", "playwright.config.*", "package.json"]
|
||||||
|
},
|
||||||
"cargo-check": {
|
"cargo-check": {
|
||||||
"inputs": ["src-tauri/src/**", "src-tauri/Cargo.toml", "src-tauri/Cargo.lock"],
|
"inputs": ["src-tauri/src/**", "src-tauri/Cargo.toml", "src-tauri/Cargo.lock"],
|
||||||
"outputs": []
|
"outputs": []
|
||||||
|
|||||||
Reference in New Issue
Block a user