feat: site languages, setup and site URL settings
This commit is contained in:
1 parent
0806733d5c
commit
d9158025d4
106 files changed
+10184
-56
No files matched your search
@@ -0,0 +1,38 @@
|
||||
# QA: Public URL pattern
|
||||
|
||||
Accepted together with features/site_public_url_pattern.feature.
|
||||
|
||||
## Automated, no server (task test)
|
||||
|
||||
1. Domain: table-driven over "Patterns that are refused" and "Writing the pattern" and the check order. Assert the new Err sentinels with errors.Is.
|
||||
2. HTTP: the existing site handler over use cases with in-memory fakes, a fresh chi.NewRouter mirroring NewSiteRouter, validator.InitValidator(), httptest, jwt cookie. Cover GET /v1/site/ (key set, new field) and PATCH /v1/site/{id}: 200, 401, 403, 422 with exact plain-text bodies, and a PATCH without the field. Assert no new route exists.
|
||||
3. Regression: the existing site tests untouched.
|
||||
|
||||
## Automated, SQLite file (task test)
|
||||
|
||||
4. The column migration is covered in the site_languages QA step 5. Round-trip a pattern of 512 characters and refuse 513.
|
||||
|
||||
## Automated (Vitest + Vue Test Utils, task test:web)
|
||||
|
||||
5. One spec per row of "Public URL states". Assert exact copy, that Save is disabled for each invalid state, the live preview, the PATCH body (value or null) sent to /v1/site/{id}, and the mapping of server 422 codes to the same messages.
|
||||
6. Mock set: GET /v1/site/ with Journal set, Journal unset, GET /v1/article/ with one article (title "Comment nous chiffrons une rénovation de salle de bain", lang fr), PATCH 200, PATCH 422.
|
||||
7. Route guard: a reader sees the Read-only view; an anonymous visitor is redirected.
|
||||
8. Cancel resets to the saved value without a request; a site with no articles shows no preview.
|
||||
9. i18n en/fr parity, task test:web, the type check, bun lint, a diff check for comments.
|
||||
|
||||
## Visual (task visual:check -- localization-site-languages, hard gate at 10 %)
|
||||
|
||||
10. Run once at the end of the slice (group L1b, 9 states). Desktop 1440 and mobile 390, light and dark. Board fixture Journal. The preview article is the board's French sample: it comes from the mocked article list.
|
||||
11. Skipped (no frame): save failure, load failure, no-articles preview.
|
||||
|
||||
## Assumptions recorded for gaps without a frame
|
||||
|
||||
- Cancel resets the field to the saved value.
|
||||
- No articles: no preview line.
|
||||
- Save and load failures reuse the Languages alert copy.
|
||||
- The design's GET/PUT /v1/site/{key} is replaced by the existing list and PATCH /v1/site/{id}.
|
||||
|
||||
## Manual
|
||||
|
||||
- Keyboard and focus order, error announcement, reduced motion.
|
||||
- A real owner edit on a dev server: save a pattern, reload, clear it.
|
||||
Reference in new issue
Block a user