docs(16.2): route checklist names openapi_conformance_test.go; 16.2-07 rows in the validation map
- PATTERNS: one conformCase per new admin route, enforced by TestPhase10ConformanceInventory without Docker (G-16.2-1) - VALIDATION: 16.2-07-T1 to T6 rows; the Docker-host suites now run in the gate's postgres stage instead of the Manual-Only table
This commit is contained in:
@@ -21,7 +21,7 @@ All paths are git-tracked source in their own repos (sm-journal-plugin, vue-jour
|
||||
| `modules/cabana/tx_context.go` (+withFieldWrites / FieldWritesFromContext) | utility | request-response | same file `withVirtualFields`/`VirtualFieldsFromContext` (36-60) | exact |
|
||||
| `modules/cabana/list_schema.go`, `http.go` `projectRow` (plugin column ListValue) | service | transform | `list_schema.go:22-24`, `http.go:1067` | self |
|
||||
| `modules/cabana/http.go` (Activate threading + route + field-types endpoint) | route | request-response | `http.go:74-121` (Activate), `:335-347` (file routes) | self |
|
||||
| `modules/cabana/admin_openapi.go` + phase09Routes test list | config | — | existing file-route entries in same file | self |
|
||||
| `modules/cabana/admin_openapi.go` + phase09Routes test list + `modules/cabana/openapi_conformance_test.go` (one conformCase per new admin route; TestPhase10ConformanceInventory enforces it without Docker) | config | — | existing file-route entries in same file | self |
|
||||
| `modules/cabana/README.md`, `modules/pact/README.md`, `docs/backend/...` + site nav | docs | — | Phase 10.1 widget sections in same READMEs / `docs/` partials-and-widgets page | role-match |
|
||||
| `admin/src/components/form/fields/PluginField.vue` (NEW) | component | event-driven | `admin/src/components/form/fields/WidgetField.vue` | exact |
|
||||
| `admin/src/components/form/fields/MLPluginField.vue` or MLField wiring | component | event-driven | `admin/src/components/form/fields/MLMarkdownField.vue` + `MLField.vue` | exact |
|
||||
@@ -106,7 +106,7 @@ func (s *service) fileUpload(w http.ResponseWriter, r *http.Request) {
|
||||
ctx = withTx(ctx, tx)
|
||||
sc, err := fr.scope(ctx, tx, r)
|
||||
```
|
||||
Route registration follows `g.Post("/{vendor}/{plugin}/{controller}/{id}/files/{field}", requireAjax(s.fileUpload))`, so the new route is `g.Post("/{vendor}/{plugin}/{controller}/{id}/fields/{field}/upload", requireAjax(s.fieldUpload))`. Use `s.uploadBytes` for the cap, load the record through the `FormExtendQuery` scope when `id != 0`, map `pact.FieldError` to 422 on the field, and answer 201 `{data:{url}}`. Also add an entry to `admin_openapi.go` and `phase09Routes` and rerun `scripts/check-admin-openapi.sh`.
|
||||
Route registration follows `g.Post("/{vendor}/{plugin}/{controller}/{id}/files/{field}", requireAjax(s.fileUpload))`, so the new route is `g.Post("/{vendor}/{plugin}/{controller}/{id}/fields/{field}/upload", requireAjax(s.fieldUpload))`. Use `s.uploadBytes` for the cap, load the record through the `FormExtendQuery` scope when `id != 0`, map `pact.FieldError` to 422 on the field, and answer 201 `{data:{url}}`. Also add an entry to `admin_openapi.go` and `phase09Routes`, add a conformCase for the route to `modules/cabana/openapi_conformance_test.go` (one conformCase per new admin route; TestPhase10ConformanceInventory enforces it without Docker), and rerun `scripts/check-admin-openapi.sh`.
|
||||
|
||||
---
|
||||
|
||||
|
||||
@@ -61,13 +61,21 @@ revised: "2026-10-10"
|
||||
| 16.2-03-T1, 16.2-06-T2 | 03, 06 | 2, 4 | D-02 / D-14 | — | Posts hooks: default write copied to content_html, non-default writes through the TranslationWriter, nothing for untouched content or without a writer | unit | `go -C ../sm-journal-plugin test -count=1 -run '^TestPostsEditorHooks$' ./controllers/` | ✅ | ✅ green |
|
||||
| 16.2-02-T2, 16.2-02-T3, 16.2-06-T1, 16.2-06-T3 | 02, 06 | 1, 4 | D-03 / D-04 | XSS | Element returns an untouched value byte for byte through Source, tabs, preview and reattach; raw HTML cards are escaped text; every raw tag rule; figures; links limited to http, https, mailto, relative; block reuse after edit, deletion and insertion | vitest | `npm --prefix ../sm-journal-plugin test` | ✅ | ✅ green |
|
||||
| 16.2-02-T3 | 02 | 1 | D-05 | — | Committed editor corpus equals the editor's current output | vitest | `npm --prefix ../sm-journal-plugin test -- tests/blogeditor/corpus.test.ts` | ✅ | ✅ green |
|
||||
| 16.2-03-T1, 16.2-06-T1 | 03, 06 | 2, 4 | todo resave / D-03 | — | Untouched GET-then-PUT of an HTML and a markdown post byte-identical with no notices and no translated content added; a clean edited save stores equal content and content_html per locale | integration (Postgres) | `go -C ../sm-journal-plugin test -count=1 -run TestPostsAdminResaveKeepsHTML .` | ✅ | ⚠️ Docker host (manual) |
|
||||
| 16.2-03-T1 | 03 | 2 | D-10 / D-02 | XSS | Admin post save strips unsafe markup in both columns per locale and reports it (no 422) | integration (Postgres) | `go -C ../sm-journal-plugin test -count=1 -run TestPostsAdminSaveSanitizesHTML .` | ✅ | ⚠️ Docker host (manual) |
|
||||
| 16.2-03-T2, 16.2-06-T2 | 03, 06 | 2, 4 | D-19 / D-10 | XSS | Category content: untouched saves keep imported markup and NULL, clean edit as sent, unsafe edit stripped with notices (no 422), blank to NULL, editor upload under journal/categories | integration (Postgres) | `go -C ../sm-journal-plugin test -count=1 -run '^(TestCategoriesAdminContent\|TestCategoriesAdminBlogEditor)$' .` | ✅ | ⚠️ Docker host (manual) |
|
||||
| 16.2-01-T3, 16.2-06-T2 | 01, 06 | 1, 4 | D-12 / D-18 | upload | Real-database create, show, untouched and changed update, refused update rolls back, upload in and out of the FormExtendQuery scope | integration (Postgres) | `go test -count=1 -run '^TestFieldTypeSavePostgres$' ./modules/cabana` | ✅ | ⚠️ Docker host (manual) |
|
||||
| 16.2-03-T1, 16.2-06-T1 | 03, 06 | 2, 4 | todo resave / D-03 | — | Untouched GET-then-PUT of an HTML and a markdown post byte-identical with no notices and no translated content added; a clean edited save stores equal content and content_html per locale | integration (Postgres) | `go -C ../sm-journal-plugin test -count=1 -run TestPostsAdminResaveKeepsHTML .` | ✅ | ✅ green (Docker host, gate postgres stage, 16.2-07) |
|
||||
| 16.2-03-T1 | 03 | 2 | D-10 / D-02 | XSS | Admin post save strips unsafe markup in both columns per locale and reports it (no 422) | integration (Postgres) | `go -C ../sm-journal-plugin test -count=1 -run TestPostsAdminSaveSanitizesHTML .` | ✅ | ✅ green (Docker host, gate postgres stage, 16.2-07) |
|
||||
| 16.2-03-T2, 16.2-06-T2 | 03, 06 | 2, 4 | D-19 / D-10 | XSS | Category content: untouched saves keep imported markup and NULL, clean edit as sent, unsafe edit stripped with notices (no 422), blank to NULL, editor upload under journal/categories | integration (Postgres) | `go -C ../sm-journal-plugin test -count=1 -run '^(TestCategoriesAdminContent\|TestCategoriesAdminBlogEditor)$' .` | ✅ | ✅ green (Docker host, gate postgres stage, 16.2-07) |
|
||||
| 16.2-01-T3, 16.2-06-T2 | 01, 06 | 1, 4 | D-12 / D-18 | upload | Real-database create, show, untouched and changed update, refused update rolls back, upload in and out of the FormExtendQuery scope | integration (Postgres) | `go test -count=1 -run '^TestFieldTypeSavePostgres$' ./modules/cabana` | ✅ | ✅ green (Docker host, gate postgres stage, 16.2-07) |
|
||||
| 16.2-04-T1, 16.2-06-T3 | 04, 06 | 2, 4 | D-17 / D-05 | iframe | Embed allowlist and id regex; sanitize first, expand last at each sink, never in payload transforms; stored iframe stripped; corpus safe under the mirror; Go negatives stripped the same way; corpus copies identical | node:test + cmp | `npm --prefix ../vue-journal-layer test && cmp ../vue-journal-layer/tests/fixtures/editor-corpus.json ../sm-journal-plugin/tests/blogeditor/fixtures/editor-corpus.json` | ✅ | ✅ green |
|
||||
| 16.2-01-T2, 16.2-06-T3 | 01, 06 | 1, 4 | docs | — | README/docs identifiers exist; plugin dist current | unit + script | `go test -count=1 ./cmd/summer -run TestDocsTree && bash ../sm-journal-plugin/scripts/check-dist.sh` | ✅ | ✅ green |
|
||||
| 16.2-06-T3 | 06 | 4 | all | T-16.2-29 | Phase gate: every runnable stage fail-closed, detectors self-tested | script | `bash scripts/check-phase16.2.sh --self-test && bash scripts/check-phase16.2.sh --all` | ✅ | ✅ green |
|
||||
| 16.2-07-T1 | 07 | 5 | D-19 | T-16.2-36, T-16.2-38 | Tracer: a category admin update sends one authorized purge after its commit; on a built swr site a cached page shows a change on the first request after the purge; unauthenticated, wrong-token and proxied purges refused | integration (Postgres) + e2e | `go -C ../sm-journal-plugin test -count=1 -run '^TestCategoriesAdminPurgesSiteCache$' . && pnpm -C ../vue-journal-layer run build:playground && node ../vue-journal-layer/testing/purge-check.mjs --output ../vue-journal-layer/.playground/.output --fixtures ../vue-journal-layer/testing/fixtures/acme --kind post --slug hello-acme --path /blog/hello-acme` | ✅ | ✅ green |
|
||||
| 16.2-07-T2 | 07 | 5 | D-19 | T-16.2-37, T-16.2-40, T-16.2-42 | Every admin post and category write purges after commit; boot refuses bad purge config; route-cached pages and 304s carry max-age=0; second purge after re-cache runs; payload purged; no-token server 404 | integration (Postgres) + e2e | `go -C ../sm-journal-plugin test -count=1 -run '^(TestCategoriesAdminPurgesSiteCache\|TestPostsAdminPurgesSiteCache)$' . && bash scripts/check-phase16.2.sh cache` | ✅ | ✅ green |
|
||||
| 16.2-07-T3 | 07 | 5 | D-13, D-18 | T-16.2-44 | Every inventoried admin route has a conformance case, checked without Docker; GET /field-types and the field upload route decode into their documented types with unknown fields disallowed and match admin.json; TestJournalSVGEmbed expects mlblogeditor | unit + integration (Postgres) | `go test -count=1 -short -run '^TestPhase10ConformanceInventory$' ./modules/cabana && go test -count=1 -run '^TestPhase10OpenAPIConformance$' ./modules/cabana` | ✅ | ✅ green |
|
||||
| 16.2-07-T3 | 07 | 5 | D-19 | T-16.2-37, T-16.2-39, T-16.2-41 | Purger config table, request contract, Warn on 500/401, 2 s timeout, cancelled parent context, no token in logs; layer auth, purge, body parsing and revalidation | unit + node:test | `go -C ../sm-journal-plugin test -count=1 -run '^(TestSiteCachePurgeConfig\|TestSiteCachePurgeRequest)$' ./classes/ && npm --prefix ../vue-journal-layer test` | ✅ | ✅ green |
|
||||
| 16.2-07-T3 | 07 | 5 | all | T-16.2-44 | Full gate including the Docker suites and the cache stage | script | `PHASE162_REQUIRE_POSTGRES=1 bash scripts/check-phase16.2.sh --all` | ✅ | ✅ green |
|
||||
| 16.2-07-T4 | 07 | 5 | release | T-16.2-45 | Release gate: clean trees, nothing behind origin, proposed tags absent on origin, human decision | script + human | `bash scripts/check-phase16.2.sh --self-test && test -z "$(git status --porcelain -- modules admin docs scripts cmd)" && test -z "$(git ls-remote --tags origin refs/tags/v0.1.20)"` | ✅ | ⬜ pending |
|
||||
| 16.2-07-T5 | 07 | 5 | release | T-16.2-36, T-16.2-37, T-16.2-45 | UAT deploy: smoke, binary sha256 equal, both programs running, tokens equal and never printed, on-server purge 200 with purged >= 1, nginx POST 403, no-token 401 | script (ssh) | Task 5 verify commands in 16.2-07-PLAN.md (smoke ok, deploy-ok, token-match, purge-ok) | ✅ | ⬜ pending |
|
||||
| 16.2-07-T6 | 07 | 5 | D-03, D-19 | T-16.2-46 | UAT Test 3 untouched re-saves byte-identical; UAT Test 2 category edit visible on the next view after a logged purge | psql (read-only) + human | Task 6 verify commands in 16.2-07-PLAN.md (posts-unchanged, translations-unchanged, category-purged, category-fresh) | ✅ | ⬜ pending |
|
||||
|
||||
*Status: ⬜ pending · ✅ green · ❌ red · ⚠️ flaky or manual (Docker host)*
|
||||
|
||||
@@ -88,7 +96,6 @@ revised: "2026-10-10"
|
||||
|
||||
| Behavior | Requirement | Why Manual | Test Instructions |
|
||||
|----------|-------------|------------|-------------------|
|
||||
| Testcontainers Postgres suites | todo resave, D-03, D-10, D-12, D-18, D-19 | No Docker on the dev machine | On a Docker host: `bash scripts/check-phase16.2.sh postgres` (cabana `./modules/cabana` incl. TestFieldTypeSavePostgres and TestListRelationSearchPostgres; sm-journal-plugin `./...` incl. TestPostsFormCompiles, TestPostsAdminCreateSmoke, TestPostsAdminResaveKeepsHTML, TestPostsAdminSaveSanitizesHTML, TestCategoriesAdminContent, TestCategoriesAdminBlogEditor, TestJournalSVGEmbed) |
|
||||
| Editing imported posts on UAT | Phase goal | Real browser editing of live posts | Open an imported post, save untouched (no notice, md5 unchanged), then edit and save; compare columns |
|
||||
| Strip and report on UAT | D-10 (amended) | Needs the admin session and a real save | Add a harmless style block and onclick in the source tab of an unpublished test post, save: it succeeds, the notice names both, the stored columns are equal and contain neither (plan 05 Task 3) |
|
||||
|
||||
@@ -100,7 +107,7 @@ revised: "2026-10-10"
|
||||
- [x] Sampling continuity: no 3 consecutive tasks without automated verify
|
||||
- [x] Wave 0 covers all MISSING references
|
||||
- [x] No watch-mode flags
|
||||
- [x] Feedback latency < 120s (the gate's runnable stages; the Docker suites are the manual row)
|
||||
- [x] Feedback latency < 120s for the Docker-free stages; the Docker suites run in the gate's postgres stage on a Docker host (`PHASE162_REQUIRE_POSTGRES=1 bash scripts/check-phase16.2.sh --all`, 16.2-07)
|
||||
- [x] nyquist_compliant set to true in the frontmatter
|
||||
|
||||
**Approval:** automated map complete (plan 06, 2026-10-10); the Docker-host suites and the UAT rows above stay manual
|
||||
**Approval:** automated map complete (plan 06, 2026-10-10); the Docker-host suites are automated in the gate's postgres stage since plan 07 (2026-10-10); the UAT rows above stay manual
|
||||
|
||||
Reference in New Issue
Block a user