Outside-in tests (IAWL ideas 33, 34): closed doors on the built site as anonymous, customer and editor; every public route judged
- reference/e2e/closed-doors.ts + closed-doors.spec.ts: one table of doors, asked by pnpm e2e:built in both bundlers; doors still open while the owner decides are asserted open (test.fail) with their question - listPublicRoutes / listNextRouteFiles / compareRouteSnapshot / updateRouteSnapshot (main entry), runRouteCheck (/doctor) - reference/e2e/routes.ts + routes.snapshot.json (395 routes, one reason each); pnpm routes:check [--update], first step of e2e:built - create-test-admin.ts makes an editor test account - docs: security.md sections, AGENT.md 8a, iapl-audit templates, iapl-upgrade 1.17.1, changelog draft Co-Authored-By: Claude Opus 5.5 <[email protected]>
This commit is contained in:
co-authored by
Claude Opus 5.5
parent
498b3dbf38
commit
2468390538
@@ -0,0 +1,12 @@
|
||||
/**
|
||||
* routes:check — every public route of this site (REST, GraphQL, Next route files) against the judged list in
|
||||
* e2e/routes.snapshot.json (docs/security.md "Routes nobody has judged"). Reads the config only, never the database.
|
||||
* pnpm payload run e2e/routes.ts → fails on a route nobody has judged
|
||||
* pnpm payload run e2e/routes.ts update → adds new routes with an empty reason (judge them), drops gone ones
|
||||
* (`payload run` drops `--flags`, so the word is `update`.) From the plugin repository: pnpm routes:check [--update],
|
||||
* also the first step of pnpm e2e:built.
|
||||
*/
|
||||
import config from '@payload-config'
|
||||
import { runRouteCheck } from '@intecion/ipal-kit/doctor'
|
||||
|
||||
process.exit(await runRouteCheck({ config: await config, update: process.argv.slice(2).includes('update') }))
|
||||
Reference in New Issue
Block a user