MotirBuilding in public
MOTIR · moooon
onMotir
You’re viewing a public project. Anyone can view it — no account needed. Sign in to submit, upvote, or comment on requests.View-only — you can’t edit work items
MOTIR-429

6.13.8 E2E (playwright) — browse the public project square LOGGED OUT, search + sort by trending, click a card → its public read-only view

Done
Description

Estimate: 50m · Depends on: 6.13.6

Type: e2e (playwright) — the full discovery loop in a browser, logged out: browse the public square, search + sort by trending, and click a card through to its public read-only view, proving the discovery → view handoff end to end without a session.

The flow:

  1. Seed several public projects across MORE THAN ONE org (varied upvotes / viewers / activity + made-public times) and at least one non-public project. Do NOT sign in — visit as an anonymous (logged-out) visitor.
  2. Navigate directly to /explore (the public page — there is NO app left-nav entry) → the gallery of project CARDS renders (name / org / description / the three stats, NO "Public" pill) for the public projects across orgs; assert a seeded non-public project is ABSENT, and assert the page exposes the SEO surface (a single <h1>, a JSON-LD application/ld+json script).
  3. Switch to the Trending sort tab → assert the order reflects recent demand (the project given the fresh upvote burst is near the top); then type a search query → the gallery narrows to matching public projects; pick a category/tag → it narrows to that topic. Confirm the URL carries the rank + search + tag (reload restores the state).
  4. Click a card → it lands on that project’s 6.12.4 public read-only view (the board / issues / public roadmap); assert there are NO edit affordances and that internal fields (assignee / estimate / internal comments) are absent — the 6.12 projection still holds through the discovery entry. NB (knock-on): under the current 6.12 model the 6.12.4 view is still account-required, so the logged-out click-through would hit a sign-in redirect — this step assumes the 6.12-side anonymous revision flagged in the header lands first; until then assert the redirect, not the view.

Mind the prodect e2e selector + harness gotchas (combobox option = label + secondary; exact/level on heading selectors; the empty-state headings; run the dev server yourself + reuse it). Drive the real UI, not API shortcuts.

Acceptance criteria

  • The square opens at /explore for a LOGGED-OUT visitor (no app left-nav entry) and renders the cross-org card gallery (no "Public" pill); a seeded non-public project is absent; the SEO surface (single <h1> + JSON-LD) is present.
  • Sorting by Trending reflects recent demand; a search query + a category/tag each narrow the gallery; the rank + search + tag are in the URL (reload restores state).
  • Clicking a card lands on the project’s 6.12.4 public view with no edit affordances + internal fields absent (the projection holds through discovery).
  • The test drives the real UI (no API-only shortcuts) and follows the prodect E2E selector + run-harness conventions.

Context refs

  • 6.13.6 (the square UI driven) — the gallery + tabs + search/filter + the card link; 6.13.2/6.13.3/6.13.4 exercised through it.
  • scripts/plan-seed/data/story-6.12.ts § 6.12.10 — the public-view e2e whose harness + selectors this builds on (the card click lands in the 6.12.4 view it drives).
  • motir-core/e2e/ — the existing Playwright specs + the run-harness + selector conventions to mirror.