# Manual verification — Puzzle Maker Pro Online

Run top-to-bottom on a real WordPress site (6.0+, PHP 7.4+ with the zip
extension). These are the acceptance criteria that could not be verified
autonomously on Linux (no WordPress runtime); step numbers refer to
`PuzzleMakerPro.Docs/Codex/Plans/wordpress-plugin-customerjson-rebuild-plan.md`.

**Prerequisite:** the engine build that includes the `[data-pmp-engine-root]`
mount support (plan Step 1.1) must be uploaded to the engine base URL you
test against — production `/v1/` or a local build via the settings override.

## Install & activate (Step 2.2)

- [ ] Plugins → Add New → Upload `wp-puzzle-maker-pro-online-v0.9.0.zip` → activate. No fatals, no notices.
- [ ] "Puzzle Catalogs" menu appears with list columns: Puzzle Type, Puzzles, Batch ID, Shortcode, Date.
- [ ] Permalinks: a new catalog post previews at `/puzzles/<slug>/` (flush permalinks if you skipped activation).

## Import a real catalog (Step 2.3)

- [ ] In Puzzle Maker Pro, export an HTML batch (e.g. Queens). Zip the batch folder (or its contents — both layouts work).
- [ ] Create a Puzzle Catalog post → Catalog Upload box → choose the zip → Update.
- [ ] Success notice shows file count + puzzle type; `index.html` listed as skipped.
- [ ] `wp-content/uploads/pmp-catalogs/<post_id>/` contains the catalog JSON + per-puzzle JSONs with the zip's relative layout intact.
- [ ] Admin columns now show type / count / batch id for the post.

## Hostile zip spot check (Step 2.3)

- [ ] Zip containing a `.php` file and an entry named `../evil.json` (build one with `tests/test-zip-validation.php` patterns): import succeeds, both entries reported as skipped, nothing written outside the post's folder.
- [ ] Zip with no catalog JSON: import rejected with a clear error notice; existing files untouched.

## Replace & delete (Step 2.3)

- [ ] Upload a different batch zip on the same post: old files gone, new files present, meta updated.
- [ ] Delete the post permanently: `uploads/pmp-catalogs/<post_id>/` is removed.

## Rendering (Step 2.4)

- [ ] Visit the catalog post's own page: the player renders; the picker lists every puzzle from the catalog; a puzzle is playable (Verify/Reset work).
- [ ] View source: the mount div has `data-pmp-engine-root`, an **absolute** `data-puzzles-base` URL under `/wp-content/uploads/pmp-catalogs/`, and the catalog filename in `data-catalog`; the engine script tag has `type="module"`.
- [ ] Put `[pmp_catalog id="<post_id>"]` on a normal page: same player renders there.
- [ ] `[pmp_catalog slug="<post-slug>"]` also resolves.
- [ ] Two shortcodes on one page: first renders, second shows the one-per-page notice (visible to editors only).
- [ ] A catalog post with no upload yet: editors see the "no catalog uploaded" notice; logged-out visitors see nothing.
- [ ] Browser console: no CORS errors loading `puzzle-engine.js`/`.css` from the engine host.

## v1.1 — Preflight (v1.1 Step 3.1)

- [ ] On the catalog edit screen, select a valid batch zip: an inline summary appears within a second or two (file count, type(s), batch id, catalog filename, skipped entries) — before clicking Update.
- [ ] Select an invalid zip (e.g. no catalog JSON): the precise rejection reason appears inline; saving still re-validates.
- [ ] Select a mixed-type zip: all types are listed.

## v1.1 — Taxonomies & auto-assignment (v1.1 Steps 1.1, 2.1)

- [ ] Catalog Categories and Catalog Tags appear under the Puzzle Catalogs menu and as edit-screen meta boxes; they do NOT appear on regular posts.
- [ ] Import a single-type catalog: category AND tag both get the type with a pretty name ("Queens", slug `queens`); the admin Puzzle Type column shows it.
- [ ] Import a mixed catalog: category is "Mixed" (slug `mixed`); each contained type appears as a tag; the Puzzle Type column lists all types comma-separated.
- [ ] Rename a type term's display name in admin, re-import: the renamed term is reused (matched by slug), not recreated.
- [ ] Manually add a category, re-upload the zip: the manual term survives.
- [ ] Term archive (`/puzzle-category/queens/`) lists the catalog (flush permalinks once after updating).

## v1.1 — [pmp_catalog_list] (v1.1 Step 4.1)

- [ ] `[pmp_catalog_list]` on a page lists published catalogs (linked titles + types + puzzle counts), newest first.
- [ ] `category`, `tag`, and `type` attributes each narrow the list; combined filters intersect; `orderby="title"` sorts alphabetically.
- [ ] An impossible filter shows the editor-only notice (nothing for logged-out visitors).

## v1.1 — Demo catalogs (v1.1 Steps 5.1, 5.2)

- [ ] Settings → Install demo catalogs: one published post appears ("Demo: Mixed Puzzles") with imported content and auto-assigned category terms.
- [ ] The mixed demo's page plays all ten puzzle types; the picker shows the per-item titles.
- [ ] Click the button again: still exactly one demo post (re-imported, not duplicated).
- [ ] Delete a demo post permanently: its `uploads/pmp-catalogs/<id>/` folder is removed.

## Settings (Step 2.5)

- [ ] Puzzle Catalogs → Settings: set Engine base URL to a locally served engine build (`npm run build` in `Web/PuzzleEngine`, then serve `dist/` at e.g. `http://localhost:5174/`): the page now loads the engine from there.
- [ ] Clear the field: production engine URL is used again.
