QA Test Tutorial Skill
Use this as the single skill whenever the user asks for a manual test tutorial/roteiro for a
ticket or feature that has already been implemented and merged (not a plan for future work).
Typical triggers (PT-BR): "faz um tutorial de como testar", "como o QA pode testar isso", "passo a
passo de teste manual", "gera o roteiro de teste pro QA", "escreve como se fosse um tutorial".
This skill has two phases that always run back-to-back by default — Phase A (write) and
Phase B (execute + evidence). Do not stop after Phase A waiting for a second request; only skip
Phase B if the dev environment is unreachable or the user explicitly asks for text only (e.g. "só
escreve o tutorial, não precisa rodar agora").
Non-negotiable security rule (applies to both phases, especially Phase B)
Never type, read, log, or store a password, token, or any credential — for any user, in any
step. All SSO/login steps must be completed manually by the human, in the browser window opened
by playwright-cli. The skill only drives the browser after the human confirms the session is
authenticated. This rule cannot be relaxed by convenience.
Phase A — Write the tutorial
Mandatory investigation before writing a single line
- Identify the ticket. Use the current branch name,
specs/<TICKET>.md (present in most
repos), or ask the user if ambiguous.
- Confirm the real, shipped implementation — read git log/diff and merged PRs in every
repository involved. Never base the tutorial only on planning docs
(
docs/tasks/<TICKET>/PRD.md, PROMPT.md) — these are frequently stale relative to what
actually shipped (confirmed pattern in this codebase: CTR-1616's docs described a superseded
Kafka-contract approach that was never implemented).
- Locate every real entry point via grep/view in the source code — never invent or assume:
- UI button labels, field names, dialog copy (e.g. confirmed via
TaskDetailsDialog.vue: "Aprovar"/"Recusar", a required "Observações" field on reject only).
- API endpoints/DTOs (controllers).
- Dev environment URLs — this ecosystem follows the convention
https://<repo-name>.dev.scansource.com.br (e.g. customers-manager-ui.dev.scansource.com.br,
tasks-manager-ui.dev.scansource.com.br). Confirm each URL from public/config.json or repo
docs before using it — never guess a URL without at least one supporting reference.
- Cover, whenever applicable: the main happy path, relevant variations (with/without an optional
field, different document/veredict types, etc.), and at least one negative/guard case (who
should NOT be affected, a state that should NOT trigger the behavior).
Fixed output format
- Title:
Tutorial: Testando a <funcionalidade> (<TICKET>).
- Section "O que você vai testar" — one paragraph, plain language.
- Section "Antes de começar" — prerequisites: how many test users/roles are needed, what access
each one needs, which environment.
- Numbered steps (
## Passo N — <título>), each with sub-steps and a closing line
✅ **Resultado esperado**: ....
- Negative/guard cases, in the same step format.
- Optional section "Verificação técnica" (DevTools/logs) when it adds real value.
- Closing note for any non-obvious behavior (e.g. a precondition that causes silent no-op rather
than an error).
Anti-hallucination rule
Every button label, field name, endpoint, message, or URL quoted in the tutorial must have been
confirmed by grep/view against the real code in this run (or reused from an already-validated
investigation earlier in the same session). Never assume a label by convention alone.
Phase B — Execute the tutorial and capture evidence (always, by default)
As soon as Phase A produces the tutorial, immediately continue into Phase B using that same
tutorial as the execution script. Do not wait for a separate request.
Steps
- Discover/confirm the test users the tutorial needs (however many roles it requires — e.g.
2 for CTR-1616: a requester and an approver/analyst). Use the Applications Manager
(
applications-manager-ui, real dev environment — not the local Keycloak seed some repos ship
under keycloak/realm.json, which is local-only and unrelated to dev) to locate existing users
in the right group, or — with the user's explicit confirmation — create new ones. The skill may
fill non-sensitive fields (name, email, group) but must never set/see a password; the human sets
credentials directly in the browser if a user needs to be created.
- Open one named
playwright-cli session per user/role (e.g. -s=userA, -s=userB) at the
dev URLs identified in Phase A.
- Pause and ask the human to complete SSO login manually in each opened window before the
skill drives any further interaction in that session. Confirm the authenticated state (e.g. via
playwright-cli snapshot) before proceeding.
- Execute every step of the Phase A tutorial, in order, taking a
playwright-cli screenshot --filename=... at each "✅ Resultado esperado" checkpoint (and at any
other transition worth documenting).
- Save all screenshots directly under the user's
Documents folder, never only in the
session workspace — the session workspace (files/<TICKET>-evidencias/) is temporary/hard to
find, and the user should never have to go hunting for the evidence. Use:
$env:USERPROFILE\Documents\<TICKET>-evidencias\ (Windows) — resolve $env:USERPROFILE
explicitly, never hardcode a username. Use sequential, descriptive filenames that mirror the
tutorial steps (e.g. 01-solicitacao-enviada.png, 02-task-recusada.png,
03-notificacao-sino.png). If a prior/partial run already left evidence in the session
workspace, copy or move it into this same Documents folder so everything ends up in one place.
When redoing a run to fix incorrect evidence, keep any genuinely historical/investigation
screenshots (e.g. proving a bug that was later fixed) in a clearly named subfolder (e.g.
historico-investigacao-<assunto>/) so they aren't confused with the current, correct evidence.
- Hand the final file list to the user at the end, with the full
Documents path spelled out,
ready to attach manually to the Jira US — this skill has no direct Jira access to attach files
itself.
When to skip Phase B
Only when the dev environment/URLs are not reachable (e.g. no VPN), or the user explicitly asks for
the tutorial text only. In either case, say so explicitly instead of silently skipping it.
Risks to flag during Phase B
- If a test user has no email configured in Keycloak, email/notification-dependent behavior will
silently no-op — verify this before relying on it as a test signal.
- SSO session cookies expire; if a step fails due to an expired session, ask the human to redo the
manual login for that specific session before retrying.
- If the tutorial depends on additional seed data beyond the test users (e.g. a specific pending
record), flag this during Phase A so it can be prepared before Phase B starts.
1---2name: qa-test-tutorial3description: Writes a manual QA test tutorial for an already-implemented ticket/feature and, by default, immediately executes it end-to-end with playwright-cli against the real dev environment, capturing screenshot evidence to attach to the Jira US.4---56# QA Test Tutorial Skill78Use this as the single skill whenever the user asks for a manual test tutorial/roteiro for a9ticket or feature that has **already been implemented and merged** (not a plan for future work).10Typical triggers (PT-BR): "faz um tutorial de como testar", "como o QA pode testar isso", "passo a11passo de teste manual", "gera o roteiro de teste pro QA", "escreve como se fosse um tutorial".1213This skill has **two phases that always run back-to-back by default** — Phase A (write) and14Phase B (execute + evidence). Do not stop after Phase A waiting for a second request; only skip15Phase B if the dev environment is unreachable or the user explicitly asks for text only (e.g. "só16escreve o tutorial, não precisa rodar agora").1718## Non-negotiable security rule (applies to both phases, especially Phase B)1920**Never type, read, log, or store a password, token, or any credential — for any user, in any21step.** All SSO/login steps must be completed manually by the human, in the browser window opened22by `playwright-cli`. The skill only drives the browser **after** the human confirms the session is23authenticated. This rule cannot be relaxed by convenience.2425## Phase A — Write the tutorial2627### Mandatory investigation before writing a single line28291. **Identify the ticket.** Use the current branch name, `specs/<TICKET>.md` (present in most30 repos), or ask the user if ambiguous.312. **Confirm the real, shipped implementation** — read git log/diff and merged PRs in every32 repository involved. **Never** base the tutorial only on planning docs33 (`docs/tasks/<TICKET>/PRD.md`, `PROMPT.md`) — these are frequently stale relative to what34 actually shipped (confirmed pattern in this codebase: CTR-1616's docs described a superseded35 Kafka-contract approach that was never implemented).363. **Locate every real entry point** via grep/view in the source code — never invent or assume:37 - UI button labels, field names, dialog copy (e.g. confirmed via38 `TaskDetailsDialog.vue`: "Aprovar"/"Recusar", a required "Observações" field on reject only).39 - API endpoints/DTOs (controllers).40 - **Dev environment URLs** — this ecosystem follows the convention41 `https://<repo-name>.dev.scansource.com.br` (e.g. `customers-manager-ui.dev.scansource.com.br`,42 `tasks-manager-ui.dev.scansource.com.br`). Confirm each URL from `public/config.json` or repo43 docs before using it — never guess a URL without at least one supporting reference.444. Cover, whenever applicable: the main happy path, relevant variations (with/without an optional45 field, different document/veredict types, etc.), and at least one negative/guard case (who46 should NOT be affected, a state that should NOT trigger the behavior).4748### Fixed output format49501. Title: `Tutorial: Testando a <funcionalidade> (<TICKET>)`.512. Section "O que você vai testar" — one paragraph, plain language.523. Section "Antes de começar" — prerequisites: how many test users/roles are needed, what access53 each one needs, which environment.544. Numbered steps (`## Passo N — <título>`), each with sub-steps and a closing line55 `✅ **Resultado esperado**: ...`.565. Negative/guard cases, in the same step format.576. Optional section "Verificação técnica" (DevTools/logs) when it adds real value.587. Closing note for any non-obvious behavior (e.g. a precondition that causes silent no-op rather59 than an error).6061### Anti-hallucination rule6263Every button label, field name, endpoint, message, or URL quoted in the tutorial must have been64confirmed by grep/view against the real code in this run (or reused from an already-validated65investigation earlier in the same session). Never assume a label by convention alone.6667## Phase B — Execute the tutorial and capture evidence (always, by default)6869As soon as Phase A produces the tutorial, immediately continue into Phase B using that same70tutorial as the execution script. Do not wait for a separate request.7172### Steps73741. **Discover/confirm the test users the tutorial needs** (however many roles it requires — e.g.75 2 for CTR-1616: a requester and an approver/analyst). Use the **Applications Manager**76 (`applications-manager-ui`, real dev environment — not the local Keycloak seed some repos ship77 under `keycloak/realm.json`, which is local-only and unrelated to dev) to locate existing users78 in the right group, or — with the user's explicit confirmation — create new ones. The skill may79 fill non-sensitive fields (name, email, group) but must never set/see a password; the human sets80 credentials directly in the browser if a user needs to be created.812. **Open one named `playwright-cli` session per user/role** (e.g. `-s=userA`, `-s=userB`) at the82 dev URLs identified in Phase A.833. **Pause and ask the human to complete SSO login manually** in each opened window before the84 skill drives any further interaction in that session. Confirm the authenticated state (e.g. via85 `playwright-cli snapshot`) before proceeding.864. **Execute every step of the Phase A tutorial, in order**, taking a87 `playwright-cli screenshot --filename=...` at each "✅ Resultado esperado" checkpoint (and at any88 other transition worth documenting).895. **Save all screenshots directly under the user's `Documents` folder**, never only in the90 session workspace — the session workspace (`files/<TICKET>-evidencias/`) is temporary/hard to91 find, and the user should never have to go hunting for the evidence. Use:92 `$env:USERPROFILE\Documents\<TICKET>-evidencias\` (Windows) — resolve `$env:USERPROFILE`93 explicitly, never hardcode a username. Use sequential, descriptive filenames that mirror the94 tutorial steps (e.g. `01-solicitacao-enviada.png`, `02-task-recusada.png`,95 `03-notificacao-sino.png`). If a prior/partial run already left evidence in the session96 workspace, copy or move it into this same `Documents` folder so everything ends up in one place.97 When redoing a run to fix incorrect evidence, keep any genuinely historical/investigation98 screenshots (e.g. proving a bug that was later fixed) in a clearly named subfolder (e.g.99 `historico-investigacao-<assunto>/`) so they aren't confused with the current, correct evidence.1006. **Hand the final file list to the user** at the end, with the full `Documents` path spelled out,101 ready to attach manually to the Jira US — this skill has no direct Jira access to attach files102 itself.103104### When to skip Phase B105106Only when the dev environment/URLs are not reachable (e.g. no VPN), or the user explicitly asks for107the tutorial text only. In either case, say so explicitly instead of silently skipping it.108109### Risks to flag during Phase B110111- If a test user has no email configured in Keycloak, email/notification-dependent behavior will112 silently no-op — verify this before relying on it as a test signal.113- SSO session cookies expire; if a step fails due to an expired session, ask the human to redo the114 manual login for that specific session before retrying.115- If the tutorial depends on additional seed data beyond the test users (e.g. a specific pending116 record), flag this during Phase A so it can be prepared before Phase B starts.