clone

a self-hosted multitenant nostr relay with sites, file storage, git hosting, and inbox and outbox delivery

feat/tinyagent
tinyrelay / scripts / qa / README.md
README.md 3.3K rendered
1# UI checks23Use a disposable local relay with the public fixture identity. This identity is for testing only.45```sh6go build -o /tmp/tiny-ux ./cmd/tiny7/tmp/tiny-ux tenant create --data-dir /tmp/tinyrelay-ux --name main \8 --owner 5ac640e5df8f7945381c31f435288ba3f587fbd68efb27abaf941792f9c363699/tmp/tiny-ux serve --data-dir /tmp/tinyrelay-ux --default-tenant main \10 --listen 127.0.0.1:18447 --allow-private-relays11```1213In another terminal, seed notes, articles, files and a Git repository, then check valid and malformed URLs:1415```sh16node scripts/qa/ux-fixture.mjs --data /tmp/tinyrelay-ux17node scripts/qa/ux-http-fuzz.mjs18go test ./tinyclient -run '^$' -fuzz FuzzInjectBasePreservesText -fuzztime=10s19```2021The HTTP report and browser screenshots are saved under `output/playwright/ux/`.2223For browser checks, open the fixture relay with Playwright CLI. The edge checks use a separate guest session. They cover failed requests, competing navigation, sign-in errors, new tabs and 60 seeded navigation actions.2425```sh26npx --package @playwright/cli playwright-cli -s=tiny-ux open http://127.0.0.1:1844727npx --package @playwright/cli playwright-cli -s=tiny-ux run-code \28 --filename scripts/qa/ux-browser-edges.js29```3031The full flow checks require signing in as the fixture owner. Start the local test signer, open `/signin` in that browser session and connect using the printed Bunker URL:3233```sh34BUNKER_USER_SECRET=fc1d06a0fd5e622dcf448d0b3c2fccc891a5ecf74546a7675460d92441fecfdd \35 node scripts/qa/nip46-bunker.mjs36```3738Then run the viewer, filter, history, signed form, mobile and no-JavaScript checks:3940```sh41npx --package @playwright/cli playwright-cli -s=tiny-ux run-code \42 --filename scripts/qa/ux-browser-flow.js43npx --package @playwright/cli playwright-cli -s=tiny-ux run-code \44 --filename scripts/qa/ux-browser-menu.js45```4647The menu checks cover public pages, hosted viewers and management pages with JavaScript enabled and disabled. They verify that mobile navigation starts closed, opens with a click or keyboard input, and leaves content in place. Desktop navigation remains visible.4849Each browser check returns its results and failure count. A real phone signer is still needed to verify the operating system handoff and approval screens.5051## Room attachments5253Build the relay, create a disposable tenant on port 18459, and seed the room fixture:5455```sh56go build -o /tmp/tiny-room-attachments ./cmd/tiny57/tmp/tiny-room-attachments tenant create --data-dir /tmp/tinyrelay-room-attachments --name main \58 --owner 5ac640e5df8f7945381c31f435288ba3f587fbd68efb27abaf941792f9c3636959/tmp/tiny-room-attachments serve --data-dir /tmp/tinyrelay-room-attachments --default-tenant main \60 --listen 127.0.0.1:18459 --allow-private-relays61node scripts/qa/room-attachments-fixture.mjs --relay http://127.0.0.1:18459 \62 --data /tmp/tinyrelay-room-attachments63```6465Sign in as the fixture owner using the local NIP-46 bunker, then run the browser check:6667```sh68BUNKER_USER_SECRET=fc1d06a0fd5e622dcf448d0b3c2fccc891a5ecf74546a7675460d92441fecfdd \69 node scripts/qa/nip46-bunker.mjs70npx --package @playwright/cli playwright-cli -s=tiny-room-attachments open \71 http://127.0.0.1:18459/signin --headed72npx --package @playwright/cli playwright-cli -s=tiny-room-attachments run-code \73 --filename scripts/qa/room-attachments-browser.js74```7576Screenshots are saved under `output/playwright/room-attachments/`.