@mars-stack/cli 7.0.2 → 7.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
package/template/AGENTS.md
CHANGED
|
@@ -97,12 +97,16 @@ yarn db:studio # Open Prisma Studio
|
|
|
97
97
|
2. **Document every executed plan.** All plans — whether they started in a chat, a Cursor plan file, or someone's head — must end up in `docs/exec-plans/completed/` with decisions, discoveries, and outcomes recorded. Use the `capture-conversation-context` skill.
|
|
98
98
|
3. **Feed conversations back.** Decisions, discoveries, and context that live only in chat threads are invisible to future agents. See [docs/design-docs/conversation-as-system-record.md](docs/design-docs/conversation-as-system-record.md).
|
|
99
99
|
|
|
100
|
+
## Dogfood QA
|
|
101
|
+
|
|
102
|
+
After **generator changes**, **template sync**, or before a **release**, run the manual checklist in **[docs/exec-plans/QA-dogfood-matrix.md](docs/exec-plans/QA-dogfood-matrix.md)** (happy path + edges × local / preview / prod smoke). Unchecked rows mean **not verified**. If a feature is off in `app.config.ts`, mark the row **N/A** instead of removing it.
|
|
103
|
+
|
|
100
104
|
## Pointers
|
|
101
105
|
|
|
102
106
|
- **Architecture details:** [docs/design-docs/](docs/design-docs/)
|
|
103
107
|
- **Core beliefs:** [docs/design-docs/core-beliefs.md](docs/design-docs/core-beliefs.md)
|
|
104
108
|
- **Conversation feedback:** [docs/design-docs/conversation-as-system-record.md](docs/design-docs/conversation-as-system-record.md)
|
|
105
|
-
- **Execution plans:** [docs/exec-plans/](docs/exec-plans/)
|
|
109
|
+
- **Execution plans:** [docs/exec-plans/](docs/exec-plans/) — includes [QA dogfood matrix](docs/exec-plans/QA-dogfood-matrix.md)
|
|
106
110
|
- **Quality scores:** [docs/QUALITY_SCORE.md](docs/QUALITY_SCORE.md)
|
|
107
111
|
- **Skills:** [.cursor/skills/](.cursor/skills/) — all skills use the `mars-` prefix (e.g., `mars-add-api-route/`, `mars-configure-email/`)
|
|
108
112
|
- **Rules:** [.cursor/rules/](.cursor/rules/) — all rules use the `mars-` prefix (e.g., `mars-security.mdc`, `mars-data-access.mdc`)
|
|
@@ -0,0 +1,111 @@
|
|
|
1
|
+
# Dogfood QA matrix (generated app)
|
|
2
|
+
|
|
3
|
+
Manual and automated verification that the **entire shipped surface** of this app behaves correctly end-to-end—including edge cases—in **local**, **preview**, and **production-class** environments.
|
|
4
|
+
|
|
5
|
+
**Source:** Mars monorepo [dogfood guard-rails plan](https://github.com/greaveselliott/mars/blob/main/docs/exec-plans/active/dogfood-guard-rails-generated-apps-p0.md). Update this file when you add or remove first-class features.
|
|
6
|
+
|
|
7
|
+
## How to use
|
|
8
|
+
|
|
9
|
+
1. Work **row by row**. Check the box only after the **happy path and listed edges** are exercised for that row in the given environment.
|
|
10
|
+
2. **Unchecked boxes mean “not verified”—not “passed”.** Do not infer green status from silence.
|
|
11
|
+
3. After each run, fill **Last run** with **date** (ISO `YYYY-MM-DD` is fine), **environment** (`local` / `preview` / `prod smoke`), and **commit** (short SHA or release tag you tested).
|
|
12
|
+
4. Run this matrix after **major generator or template upgrades**, before a **release**, or when changing **auth, CSRF, billing, or uploads**.
|
|
13
|
+
|
|
14
|
+
## Feature flags (`app.config.ts`)
|
|
15
|
+
|
|
16
|
+
- If a feature is **disabled** in `src/config/app.config.ts`, mark the row **N/A** in the notes column (feature not present) instead of deleting the row. If the feature is enabled but you are **skipping** verification temporarily, mark **Skip** with a short reason—still not a pass.
|
|
17
|
+
- If you **customized** Mars plumbing files, treat **user-owned** paths per `mars template sync` / upgrade docs before assuming failures are product bugs.
|
|
18
|
+
|
|
19
|
+
---
|
|
20
|
+
|
|
21
|
+
## Matrix
|
|
22
|
+
|
|
23
|
+
### Auth
|
|
24
|
+
|
|
25
|
+
- [ ] **Verified**
|
|
26
|
+
- **Happy path + edges:** sign-in, sign-up, forgot/reset, verify email, session expiry, wrong password, locked account, already logged-in redirect to dashboard.
|
|
27
|
+
- **Local** — Date: _____________ Env: _____________ Commit: _____________
|
|
28
|
+
- **Preview** — Date: _____________ Env: _____________ Commit: _____________
|
|
29
|
+
- **Prod smoke** — Date: _____________ Env: _____________ Commit: _____________
|
|
30
|
+
- **Notes (N/A / Skip):**
|
|
31
|
+
|
|
32
|
+
### Protected shell
|
|
33
|
+
|
|
34
|
+
- [ ] **Verified**
|
|
35
|
+
- **Happy path + edges:** nav, search, notifications, command palette (⌘K), theme toggle, user menu, **logout** (cookie cleared, lands on expected page).
|
|
36
|
+
- **Local** — Date: _____________ Env: _____________ Commit: _____________
|
|
37
|
+
- **Preview** — Date: _____________ Env: _____________ Commit: _____________
|
|
38
|
+
- **Prod smoke** — Date: _____________ Env: _____________ Commit: _____________
|
|
39
|
+
- **Notes (N/A / Skip):**
|
|
40
|
+
|
|
41
|
+
### Onboarding
|
|
42
|
+
|
|
43
|
+
- [ ] **Verified**
|
|
44
|
+
- **Happy path + edges:** all steps, skip where allowed, **CSRF** on step POST, mobile stepper layout.
|
|
45
|
+
- **Local** — Date: _____________ Env: _____________ Commit: _____________
|
|
46
|
+
- **Preview** — Date: _____________ Env: _____________ Commit: _____________
|
|
47
|
+
- **Prod smoke** — Date: _____________ Env: _____________ Commit: _____________
|
|
48
|
+
- **Notes (N/A / Skip):**
|
|
49
|
+
|
|
50
|
+
### Settings
|
|
51
|
+
|
|
52
|
+
- [ ] **Verified**
|
|
53
|
+
- **Happy path + edges:** display name, password change, **session list** (copy vs multi-row behaviour), revoke one / revoke all.
|
|
54
|
+
- **Local** — Date: _____________ Env: _____________ Commit: _____________
|
|
55
|
+
- **Preview** — Date: _____________ Env: _____________ Commit: _____________
|
|
56
|
+
- **Prod smoke** — Date: _____________ Env: _____________ Commit: _____________
|
|
57
|
+
- **Notes (N/A / Skip):**
|
|
58
|
+
|
|
59
|
+
### Billing / pricing
|
|
60
|
+
|
|
61
|
+
- [ ] **Verified**
|
|
62
|
+
- **Happy path + edges:** checkout/portal where Stripe enabled; gated UI when disabled.
|
|
63
|
+
- **Local** — Date: _____________ Env: _____________ Commit: _____________
|
|
64
|
+
- **Preview** — Date: _____________ Env: _____________ Commit: _____________
|
|
65
|
+
- **Prod smoke** — Date: _____________ Env: _____________ Commit: _____________
|
|
66
|
+
- **Notes (N/A / Skip):**
|
|
67
|
+
|
|
68
|
+
### Files
|
|
69
|
+
|
|
70
|
+
- [ ] **Verified**
|
|
71
|
+
- **Happy path + edges:** upload (XHR + **CSRF**), list, download, delete (**CSRF**), size limit error.
|
|
72
|
+
- **Local** — Date: _____________ Env: _____________ Commit: _____________
|
|
73
|
+
- **Preview** — Date: _____________ Env: _____________ Commit: _____________
|
|
74
|
+
- **Prod smoke** — Date: _____________ Env: _____________ Commit: _____________
|
|
75
|
+
- **Notes (N/A / Skip):**
|
|
76
|
+
|
|
77
|
+
### AI
|
|
78
|
+
|
|
79
|
+
- [ ] **Verified**
|
|
80
|
+
- **Happy path + edges:** chat send, stream, **CSRF**, provider-none vs configured behaviour.
|
|
81
|
+
- **Local** — Date: _____________ Env: _____________ Commit: _____________
|
|
82
|
+
- **Preview** — Date: _____________ Env: _____________ Commit: _____________
|
|
83
|
+
- **Prod smoke** — Date: _____________ Env: _____________ Commit: _____________
|
|
84
|
+
- **Notes (N/A / Skip):**
|
|
85
|
+
|
|
86
|
+
### Admin
|
|
87
|
+
|
|
88
|
+
- [ ] **Verified**
|
|
89
|
+
- **Happy path + edges:** users list, forbidden for non-admin.
|
|
90
|
+
- **Local** — Date: _____________ Env: _____________ Commit: _____________
|
|
91
|
+
- **Preview** — Date: _____________ Env: _____________ Commit: _____________
|
|
92
|
+
- **Prod smoke** — Date: _____________ Env: _____________ Commit: _____________
|
|
93
|
+
- **Notes (N/A / Skip):**
|
|
94
|
+
|
|
95
|
+
### Blog, dashboard, landing, coming-soon, legal, cookie consent
|
|
96
|
+
|
|
97
|
+
- [ ] **Verified**
|
|
98
|
+
- **Happy path + edges:** load + critical interaction for blog, files page, dashboard cards, landing, coming-soon, legal pages, cookie consent as applicable.
|
|
99
|
+
- **Local** — Date: _____________ Env: _____________ Commit: _____________
|
|
100
|
+
- **Preview** — Date: _____________ Env: _____________ Commit: _____________
|
|
101
|
+
- **Prod smoke** — Date: _____________ Env: _____________ Commit: _____________
|
|
102
|
+
- **Notes (N/A / Skip):**
|
|
103
|
+
|
|
104
|
+
### Edge cases (cross-cutting)
|
|
105
|
+
|
|
106
|
+
- [ ] **Verified**
|
|
107
|
+
- **Happy path + edges:** **403 CSRF** surfaces clear message (not `SyntaxError`), **mobile ~375px**, **dark mode**, **slow network** / abort, **two tabs** same user.
|
|
108
|
+
- **Local** — Date: _____________ Env: _____________ Commit: _____________
|
|
109
|
+
- **Preview** — Date: _____________ Env: _____________ Commit: _____________
|
|
110
|
+
- **Prod smoke** — Date: _____________ Env: _____________ Commit: _____________
|
|
111
|
+
- **Notes (N/A / Skip):**
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import { readFileSync } from 'node:fs';
|
|
2
|
+
import { dirname, join } from 'node:path';
|
|
3
|
+
import { fileURLToPath } from 'node:url';
|
|
4
|
+
import { describe, expect, it } from 'vitest';
|
|
5
|
+
|
|
6
|
+
const __dirname = dirname(fileURLToPath(import.meta.url));
|
|
7
|
+
const matrixPath = join(__dirname, '../docs/exec-plans/QA-dogfood-matrix.md');
|
|
8
|
+
|
|
9
|
+
/** Minimum feature slices from docs/exec-plans/active/dogfood-guard-rails-generated-apps-p0.md */
|
|
10
|
+
const REQUIRED_SECTION_TITLES = [
|
|
11
|
+
'Auth',
|
|
12
|
+
'Protected shell',
|
|
13
|
+
'Onboarding',
|
|
14
|
+
'Settings',
|
|
15
|
+
'Billing / pricing',
|
|
16
|
+
'Files',
|
|
17
|
+
'AI',
|
|
18
|
+
'Admin',
|
|
19
|
+
'Blog, dashboard, landing, coming-soon, legal, cookie consent',
|
|
20
|
+
'Edge cases (cross-cutting)',
|
|
21
|
+
] as const;
|
|
22
|
+
|
|
23
|
+
describe('QA dogfood matrix contract', () => {
|
|
24
|
+
const content = readFileSync(matrixPath, 'utf8');
|
|
25
|
+
|
|
26
|
+
it('exists and documents last-run fields per environment', () => {
|
|
27
|
+
expect(content).toContain('**Local**');
|
|
28
|
+
expect(content).toContain('**Preview**');
|
|
29
|
+
expect(content).toContain('**Prod smoke**');
|
|
30
|
+
expect(content).toMatch(/Date:\s+_+.*Commit:/s);
|
|
31
|
+
});
|
|
32
|
+
|
|
33
|
+
it('states that unchecked rows are not verified', () => {
|
|
34
|
+
expect(content).toMatch(/not verified|Not verified/i);
|
|
35
|
+
});
|
|
36
|
+
|
|
37
|
+
it('documents N/A vs Skip for disabled or deferred features', () => {
|
|
38
|
+
expect(content).toMatch(/N\/A|Skip/);
|
|
39
|
+
expect(content).toMatch(/app\.config\.ts/);
|
|
40
|
+
});
|
|
41
|
+
|
|
42
|
+
it.each(REQUIRED_SECTION_TITLES)('includes matrix section: %s', (title) => {
|
|
43
|
+
expect(content).toContain(`### ${title}`);
|
|
44
|
+
});
|
|
45
|
+
});
|
|
@@ -8,7 +8,7 @@ export default defineConfig({
|
|
|
8
8
|
environment: 'jsdom',
|
|
9
9
|
globals: true,
|
|
10
10
|
setupFiles: ['./vitest.setup.ts'],
|
|
11
|
-
include: ['src/**/*.test.{ts,tsx}'],
|
|
11
|
+
include: ['src/**/*.test.{ts,tsx}', 'scripts/**/*.test.ts'],
|
|
12
12
|
passWithNoTests: true,
|
|
13
13
|
coverage: {
|
|
14
14
|
provider: 'v8',
|