Documentation
¶
Overview ¶
Command mkteampage makes, reads and removes a TEAM'S PAGE (migration 0165) on the e2e database, for tests/team-pages.spec.ts: a team the operator (user 1) is a VIEWER of, a second person who is the page's CREATOR (the person who started the team agent that made it), and a two-version page the team owns. The signed-in operator is then a member who is not the creator.
DATABASE_URL=…_e2e go run ./e2e/mkteampage create <stamp> prints {"team","name","page","creator"} as JSON
DATABASE_URL=…_e2e go run ./e2e/mkteampage responses <page> prints each owner-view response's responder id, one per line
DATABASE_URL=…_e2e go run ./e2e/mkteampage remove <team> removes the team, its page and its creator
The rows are the ones a team agent's page_create writes (pages, then page_versions) and users.CreateTeam / SetTeamMember write (a users row of kind 'team', its memberships), written as the login role.
🔴 IT REFUSES ANY DATABASE WHOSE NAME DOES NOT END IN "_e2e" (e2edb.Check): it writes users, team_members and pages as the login role, which nothing outside a fixture may do.