Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
37 changes: 37 additions & 0 deletions .github/workflows/pr-quality.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
name: PR Quality
Comment thread
max23468 marked this conversation as resolved.

on:
pull_request:
branches:
- main
workflow_dispatch:

permissions:
contents: read

jobs:
test-build-coverage:
name: Test, coverage e build
runs-on: ubuntu-latest

steps:
- name: Checkout
uses: actions/checkout@v6

- name: Setup Node
uses: actions/setup-node@v6
with:
node-version: 24
cache: npm

- name: Install
run: npm ci

- name: Test
run: npm test

- name: Coverage core
run: npm run test:coverage

- name: Build
run: npm run build
12 changes: 12 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ Monitor configurati:
npm install
npm run build
npm test
npm run test:coverage
npm run sentinel -- scan
npm run sentinel -- scan --dry-run
npm run sentinel -- report
Expand Down Expand Up @@ -113,6 +114,17 @@ Su macOS, se la password non è in env, Sentinel prova a leggere dal Portachiavi
- [docs/TOOLCHAIN.md](docs/TOOLCHAIN.md): runtime, workflow e verifiche.
- [docs/DECISIONS.md](docs/DECISIONS.md): decisioni stabili.

## Coverage core

Per l'audit Atlas la coverage Vitest ufficiale passa da:

```bash
npm run test:coverage
```

Il perimetro core attuale è dichiarato in `vitest.config.ts` e applica soglie
minime `75%` linee e `65%` branch sui moduli core selezionati.

## Pubblicazione

La pubblicazione codice passa da GitHub. Il deploy operativo MVP passa dal
Expand Down
12 changes: 12 additions & 0 deletions docs/TOOLCHAIN.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ Questa pagina descrive runtime, comandi e guardrail effettivi di Sentinel.
| Vercel CLI | locale/autenticata | deploy dashboard web senza GitHub Actions |
| Vercel Blob | privato | payload dinamico dashboard e ultimi report |
| GitHub Actions | `ubuntu-latest`, Node `24` | runtime operativo schedulato/manuale |
| GitHub Actions PR Quality | `ubuntu-latest`, Node `24` | gate PR su test, coverage core e build |
| Dependabot | configurazione GitHub | aggiornamenti dipendenze npm e GitHub Actions |
| SMTP Gmail | Doppler, secret GitHub o env locale | invio email operativo |
| Portachiavi macOS | servizi `sentinel-gmail` e `sentinel-icloud` | fallback locale per password email |
Expand All @@ -45,6 +46,8 @@ Questa pagina descrive runtime, comandi e guardrail effettivi di Sentinel.
- install/setup: `npm install` o `npm ci`.
- build: `npm run build`.
- test: `npm test`.
- coverage core Atlas: `npm run test:coverage`.
- gate PR quality: workflow `.github/workflows/pr-quality.yml`.
- Codex comments dry-run: workflow `Codex PR comments` con input `dry_run=true`.
- scan: `npm run sentinel -- scan`.
- dry-run scan: `npm run sentinel -- scan --dry-run`.
Expand All @@ -59,6 +62,14 @@ Questa pagina descrive runtime, comandi e guardrail effettivi di Sentinel.
- test email Gmail: `npm run sentinel -- test-email --profile gmail`.
- test email iCloud: `npm run sentinel -- test-email --profile icloud`.

## Coverage core

- La coverage Vitest ufficiale per l'audit Atlas gira con `npm run test:coverage`.
- Il perimetro core corrente è dichiarato in `vitest.config.ts`.
- Le soglie minime correnti sul perimetro core sono `75%` linee e `65%` branch.
- La coverage non sostituisce `npm test` e `npm run build`: è un gate aggiuntivo
quando il lavoro tocca test, quality bar o moduli core.

## Verifiche per scope

| Tipo modifica | Corsia | Verifiche minime |
Expand All @@ -67,6 +78,7 @@ Questa pagina descrive runtime, comandi e guardrail effettivi di Sentinel.
| Docs-only | veloce | Review documentale e `git diff --check` quando utile |
| Workflow/config o documenti operativi critici | standard | Review mirata e comando collegato al file modificato |
| Test-only, CLI o dashboard piccola | standard | `npm test`, `npm run build` o test mirati |
| Audit test/coverage o quality bar moduli core | standard | `npm test`, `npm run test:coverage`, `npm run build` |
| Runtime schedulato, dati/output, provider email, deploy/config, release/versioning o UI sostanziale | completa | Gate completo proporzionato, smoke/manual run quando serve, React Doctor se applicabile |

Per UI sostanziale della dashboard Next.js usare anche browser locale o deploy
Expand Down
Loading
Loading