|
|
@@ -414,44 +414,7 @@ Before committing tests, ensure:
|
|
|
|
|
|
## Running Tests
|
|
|
|
|
|
-### From Monorepo Root (Recommended)
|
|
|
-
|
|
|
-```bash
|
|
|
-# Run all tests for a specific package
|
|
|
-turbo run test --filter @growi/app
|
|
|
-turbo run test --filter @growi/core
|
|
|
-
|
|
|
-# Or with Turborepo caching
|
|
|
-pnpm run test --filter @growi/app
|
|
|
-```
|
|
|
-
|
|
|
-### From Package Directory
|
|
|
-
|
|
|
-```bash
|
|
|
-# Run all tests
|
|
|
-pnpm vitest run
|
|
|
-
|
|
|
-# Run specific test file (use partial file name)
|
|
|
-pnpm vitest run yjs.integ
|
|
|
-pnpm vitest run helper.spec
|
|
|
-pnpm vitest run Button.spec
|
|
|
-
|
|
|
-# Run tests matching a pattern
|
|
|
-pnpm vitest run PageService
|
|
|
-```
|
|
|
-
|
|
|
-**File pattern tips**:
|
|
|
-- Use **partial file name** - Vitest automatically finds matching files
|
|
|
-- No need for `src/` prefix or full path
|
|
|
-- No need for `--project` flag - Vitest auto-detects based on file extension
|
|
|
-- Works across all packages (apps/app, packages/core, etc.)
|
|
|
-
|
|
|
-### Running Multiple Times (Flaky Test Detection)
|
|
|
-
|
|
|
-```bash
|
|
|
-# Repeat test execution to verify stability
|
|
|
-pnpm vitest run yjs.integ --repeat=10
|
|
|
-```
|
|
|
+See the `testing` rule (`.claude/rules/testing.md`) for test execution commands.
|
|
|
|
|
|
## Summary: GROWI Testing Philosophy
|
|
|
|