| Dimension | Shared | Only in A | Only in B | Overlap |
|---|---|---|---|---|
| Sections | 0 | 1 | 1 | 0% |
| Commands | 0 | 0 | 2 | 0% |
| Section tags | 1 | 0 | 2 | 33% |
What each file covers
Sections
0 shared · 1 only in A · 1 only in B- − Novu Conventions
- + Testing Conventions
Commands
0 shared · 0 only in A · 2 only in B- + npm run lint:openapi
- + pnpm start:worker
Section tags
1 shared · 0 only in A · 2 only in B- + test
- + testing-strategy
- code-style
Line diff
novuhq/novu · .cursor/rules/novu.mdc
@@ −1 @@
1---
2description:
3globs:
4alwaysApply: true
5---
6### Novu Conventions
7
8- File/directory names: lowercase with dashes (`components/auth-wizard`)
9- Named exports for all components
10- TypeScript: `interface` on the backend, `type` on the frontend — this is the project convention and overrides any general "prefer interfaces" guidance
11- Blank line before every `return` statement
12- Animations: import from `"motion/react"` — not `"framer-motion"` or `"motion-react"`
13- No nested ternaries
14
novuhq/novu · .cursor/rules/testing.mdc
@@ +1 @@
1---
2description: Rules for writing and running tests
3globs:
4 - "**/*.spec.ts"
5 - "**/*.test.ts"
6 - "**/e2e/**"
7alwaysApply: false
8---
9
10### Testing Conventions
11
12**General**
13- Match the test style and tooling already used in the same app (Mocha for API/worker, Playwright for dashboard).
14- Shared test utilities and setup helpers live in `libs/testing` — use them instead of rolling custom harnesses.
15- Never mock MongoDB models directly; use the test harness in `libs/testing` which manages real database state.
16
17**API (`apps/api`)**
18- Unit tests: `cd apps/api && pnpm test` (Mocha + ts-node, matches `src/**/*.spec.ts`)
19- Lint: `cd apps/api && pnpm check`
20- OpenAPI validation: `npm run lint:openapi` (requires API running)
21- E2E tests: see `.cursor/skills/run-api-e2e-tests/SKILL.md`
22- Bootstrap a NestJS testing module for integration-style unit tests rather than mocking the entire DI container.
23
24**Dashboard (`apps/dashboard`)**
25- E2E tests: `cd apps/dashboard && pnpm test:e2e` (Playwright — start dashboard first)
26- Lint: `cd apps/dashboard && pnpm check`
27- Tests live in `apps/dashboard/tests/` (or `e2e/`).
28
29**Worker (`apps/worker`)**
30- Unit tests: `cd apps/worker && pnpm test` (Mocha + ts-node, matches `src/**/**/*.spec.ts`)
31- Lint: `cd apps/worker && pnpm check`
32- The worker must be running (`pnpm start:worker`) when testing end-to-end notification flows.
33
@@ −1 +1 @@
11 ---
2−description:
3−globs:
4−alwaysApply: true
2+description: Rules for writing and running tests
3+globs:
4+ - "**/*.spec.ts"
5+ - "**/*.test.ts"
6+ - "**/e2e/**"
7+alwaysApply: false
58 ---
6−### Novu Conventions
79
8−- File/directory names: lowercase with dashes (`components/auth-wizard`)
9−- Named exports for all components
10−- TypeScript: `interface` on the backend, `type` on the frontend — this is the project convention and overrides any general "prefer interfaces" guidance
11−- Blank line before every `return` statement
12−- Animations: import from `"motion/react"` — not `"framer-motion"` or `"motion-react"`
13−- No nested ternaries
10+### Testing Conventions
11+
12+**General**
13+- Match the test style and tooling already used in the same app (Mocha for API/worker, Playwright for dashboard).
14+- Shared test utilities and setup helpers live in `libs/testing` — use them instead of rolling custom harnesses.
15+- Never mock MongoDB models directly; use the test harness in `libs/testing` which manages real database state.
16+
17+**API (`apps/api`)**
18+- Unit tests: `cd apps/api && pnpm test` (Mocha + ts-node, matches `src/**/*.spec.ts`)
19+- Lint: `cd apps/api && pnpm check`
20+- OpenAPI validation: `npm run lint:openapi` (requires API running)
21+- E2E tests: see `.cursor/skills/run-api-e2e-tests/SKILL.md`
22+- Bootstrap a NestJS testing module for integration-style unit tests rather than mocking the entire DI container.
23+
24+**Dashboard (`apps/dashboard`)**
25+- E2E tests: `cd apps/dashboard && pnpm test:e2e` (Playwright — start dashboard first)
26+- Lint: `cd apps/dashboard && pnpm check`
27+- Tests live in `apps/dashboard/tests/` (or `e2e/`).
28+
29+**Worker (`apps/worker`)**
30+- Unit tests: `cd apps/worker && pnpm test` (Mocha + ts-node, matches `src/**/**/*.spec.ts`)
31+- Lint: `cd apps/worker && pnpm check`
32+- The worker must be running (`pnpm start:worker`) when testing end-to-end notification flows.
1433
