Spaces:
Runtime error
Runtime error
Nyk commited on
Commit ·
5b92f6b
1
Parent(s): adb0663
fix: CI workflow and release readiness bugs
Browse files- Swap pnpm/node setup order (pnpm must install before node cache)
- Move build step before E2E tests (next start needs .next/ output)
- Add `cp .env.test .env` step so E2E server has auth credentials
- Fix test:all script to build before E2E (same ordering bug)
- Remove stale package-lock.json (project uses pnpm exclusively)
- Update README: remove "No E2E test suite" (52 tests exist now)
- .github/workflows/quality-gate.yml +14 -11
- .gitignore +3 -0
- README.md +2 -4
- package-lock.json +0 -0
- package.json +1 -1
.github/workflows/quality-gate.yml
CHANGED
|
@@ -16,23 +16,20 @@ jobs:
|
|
| 16 |
- name: Checkout
|
| 17 |
uses: actions/checkout@v4
|
| 18 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 19 |
- name: Setup Node
|
| 20 |
uses: actions/setup-node@v4
|
| 21 |
with:
|
| 22 |
node-version: 20
|
| 23 |
cache: 'pnpm'
|
| 24 |
|
| 25 |
-
- name: Setup pnpm
|
| 26 |
-
uses: pnpm/action-setup@v4
|
| 27 |
-
with:
|
| 28 |
-
version: 10
|
| 29 |
-
|
| 30 |
- name: Install dependencies
|
| 31 |
run: pnpm install --frozen-lockfile
|
| 32 |
|
| 33 |
-
- name: Install Playwright browsers
|
| 34 |
-
run: pnpm exec playwright install --with-deps
|
| 35 |
-
|
| 36 |
- name: Lint
|
| 37 |
run: pnpm lint
|
| 38 |
|
|
@@ -42,8 +39,14 @@ jobs:
|
|
| 42 |
- name: Unit tests
|
| 43 |
run: pnpm test
|
| 44 |
|
| 45 |
-
- name: E2E tests
|
| 46 |
-
run: pnpm test:e2e
|
| 47 |
-
|
| 48 |
- name: Build
|
| 49 |
run: pnpm build
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 16 |
- name: Checkout
|
| 17 |
uses: actions/checkout@v4
|
| 18 |
|
| 19 |
+
- name: Setup pnpm
|
| 20 |
+
uses: pnpm/action-setup@v4
|
| 21 |
+
with:
|
| 22 |
+
version: 10
|
| 23 |
+
|
| 24 |
- name: Setup Node
|
| 25 |
uses: actions/setup-node@v4
|
| 26 |
with:
|
| 27 |
node-version: 20
|
| 28 |
cache: 'pnpm'
|
| 29 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 30 |
- name: Install dependencies
|
| 31 |
run: pnpm install --frozen-lockfile
|
| 32 |
|
|
|
|
|
|
|
|
|
|
| 33 |
- name: Lint
|
| 34 |
run: pnpm lint
|
| 35 |
|
|
|
|
| 39 |
- name: Unit tests
|
| 40 |
run: pnpm test
|
| 41 |
|
|
|
|
|
|
|
|
|
|
| 42 |
- name: Build
|
| 43 |
run: pnpm build
|
| 44 |
+
|
| 45 |
+
- name: Prepare E2E environment
|
| 46 |
+
run: cp .env.test .env
|
| 47 |
+
|
| 48 |
+
- name: Install Playwright browsers
|
| 49 |
+
run: pnpm exec playwright install --with-deps
|
| 50 |
+
|
| 51 |
+
- name: E2E tests
|
| 52 |
+
run: pnpm test:e2e
|
.gitignore
CHANGED
|
@@ -14,6 +14,9 @@ dist/
|
|
| 14 |
*.pem
|
| 15 |
.env*.local
|
| 16 |
|
|
|
|
|
|
|
|
|
|
| 17 |
# Debug
|
| 18 |
npm-debug.log*
|
| 19 |
yarn-debug.log*
|
|
|
|
| 14 |
*.pem
|
| 15 |
.env*.local
|
| 16 |
|
| 17 |
+
# npm (project uses pnpm)
|
| 18 |
+
package-lock.json
|
| 19 |
+
|
| 20 |
# Debug
|
| 21 |
npm-debug.log*
|
| 22 |
yarn-debug.log*
|
README.md
CHANGED
|
@@ -58,9 +58,8 @@ Initial login is seeded from `AUTH_USER` / `AUTH_PASS` on first run.
|
|
| 58 |
|
| 59 |
### Known Limitations
|
| 60 |
|
| 61 |
-
- **Minimal test coverage** — Vitest unit test stubs and Playwright E2E config exist, but comprehensive tests are still needed
|
| 62 |
- **CSP still includes `unsafe-inline`** — `unsafe-eval` has been removed, but inline styles remain for framework compatibility
|
| 63 |
-
- **
|
| 64 |
|
| 65 |
### Security Considerations
|
| 66 |
|
|
@@ -336,8 +335,7 @@ See [open issues](https://github.com/builderz-labs/mission-control/issues) for t
|
|
| 336 |
|
| 337 |
#### Up Next
|
| 338 |
|
| 339 |
-
- [ ]
|
| 340 |
-
- [ ] Fill in Vitest test stubs with real assertions
|
| 341 |
- [ ] API token rotation UI
|
| 342 |
- [ ] Webhook signature verification
|
| 343 |
|
|
|
|
| 58 |
|
| 59 |
### Known Limitations
|
| 60 |
|
|
|
|
| 61 |
- **CSP still includes `unsafe-inline`** — `unsafe-eval` has been removed, but inline styles remain for framework compatibility
|
| 62 |
+
- **Vitest stubs need real assertions** — unit test files exist but most are placeholder stubs
|
| 63 |
|
| 64 |
### Security Considerations
|
| 65 |
|
|
|
|
| 335 |
|
| 336 |
#### Up Next
|
| 337 |
|
| 338 |
+
- [ ] Fill in Vitest unit test stubs with real assertions
|
|
|
|
| 339 |
- [ ] API token rotation UI
|
| 340 |
- [ ] Webhook signature verification
|
| 341 |
|
package-lock.json
DELETED
|
The diff for this file is too large to render.
See raw diff
|
|
|
package.json
CHANGED
|
@@ -12,7 +12,7 @@
|
|
| 12 |
"test:watch": "vitest",
|
| 13 |
"test:ui": "vitest --ui",
|
| 14 |
"test:e2e": "playwright test",
|
| 15 |
-
"test:all": "pnpm lint && pnpm typecheck && pnpm test && pnpm
|
| 16 |
"quality:gate": "pnpm test:all"
|
| 17 |
},
|
| 18 |
"dependencies": {
|
|
|
|
| 12 |
"test:watch": "vitest",
|
| 13 |
"test:ui": "vitest --ui",
|
| 14 |
"test:e2e": "playwright test",
|
| 15 |
+
"test:all": "pnpm lint && pnpm typecheck && pnpm test && pnpm build && pnpm test:e2e",
|
| 16 |
"quality:gate": "pnpm test:all"
|
| 17 |
},
|
| 18 |
"dependencies": {
|