본문으로 건너뛰기
cccskills
무료GitHub에 공개

test-environment-selection

Use before booting anything - choosing local (start_task_preview or a workspace boot), the task's preview or stage, confirming the build is the PR head, and what to do when nothing can run

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

연동 도구Vercel
설치 방법 보기

포함된 파일(1)

  • SKILL.md5.2 KB

SKILL.md(원문)

설치하기 전에 에이전트에게 전달되는 지시 내용을 확인할 수 있습니다.

Test Environment Selection

Overview

Before executing a single scenario, decide WHERE the product will run, in this order:

  1. Backend, worker or full-stack repository: local. DB rows, logs and third-party stubs are only observable there. First choice start_task_preview — it checks out the task branch in the task workspace, detects how to run it, starts it, stops a stale server, and returns a localhost URL for the browser tools; call it again if the URL isn't there yet. Only when it cannot run the project (e.g. a backend+frontend pair, or a worker it doesn't detect), boot by hand (backend-manual-testing).
  2. Frontend-only repository: the task's own preview, else local. When the component is deployed with a per-branch preview environment, get_task_preview returns it — use it when status: "ready" AND built_from_pr_head: true. Anything else (building, built_from_pr_head: false, error, canceled, none, or an empty list) is not the code under test: fall back to start_task_preview.
  3. Stage. Used when the repository is configured for stage verification, or when the app cannot boot locally (managed secrets, heavy infra the workspace lacks) — always after confirming stage is actually running the PR head (see Stage rules).

Production is never a test environment. No scenario is ever executed against the prod base URL or prod data — not a "harmless" GET, not seeding, not cleanup.

How to decide

  1. Identify the repository shape (backend/worker/full-stack vs frontend-only) and apply the order above.
  2. Read the repository settings (list_repositories): build_command, test_command, verify_command — and any comment the developer left on the task (a clean run leaves none). These are the project's declared way of running and checking itself. get_project_brief has the same information plus what each component talks to.
  3. If neither a usable preview nor a local boot nor stage works, you are blocked — see below.

Preview rules

  • Address. Use open_url in the browser (browser_navigate) — for a protected preview it carries the bypass and sets a cookie, so the pages it links to load too. For HTTP requests (curl, an API client) use branch_url (or url when there is none) and send every header in request_headers on every request.
  • Protected without a bypass. When the entry notes that the preview is behind Vercel Deployment Protection with no Protection Bypass for Automation, the preview answers every automated request with a login page. Do not report that page as a failure. Test locally instead and leave one comment asking the human to add "Protection Bypass for Automation" in the Vercel project (Settings → Deployment Protection).
  • Never write the bypass secret — nor open_url, which contains it — into a comment, test case, document or bug report: it opens the project's previews to whoever reads it. Refer to "the preview bypass" instead.
  • A preview is not prod, but its backing services may be. If the preview talks to a shared database or a third-party account, avoid destructive scenarios there exactly as on stage; they run locally only.
  • Put the preview's branch_url and short commit_sha in every review_criterion note — the next reader needs to know exactly what ran, and a pass writes no comment to say it elsewhere.

Stage rules

  • Confirm the change is actually there before testing. list_deployments (env=stage) shows the commit of the latest deploy — it must equal the PR head from get_task_pull_request. get_environment says whether stage is bound at all. Not equal → wait for the stage deploy that started when the task entered ready_for_qa (get_pipeline_status shows its progress); never test the old build.
  • Stage is shared. Namespace your test data (qa-<task-key>-... prefixes, test-data-and-stubs), avoid destructive scenarios (mass deletes, migrations, load tests) — those run locally only — and clean up what you created.
  • The stage base_url is for requests; the health_url is only a liveness probe.

When none is possible

If there is no usable preview, the app cannot boot in the workspace (including via start_task_preview) AND no stage target exists (or it isn't running the PR head), do not fake a verdict and do not read the code as a substitute. Apply the blocker triage (qa-verify-before-verdict): the project cannot boot from its own documented commands → need_revision with the failing command and its output, a developer-fixable defect. A blocker only a human can lift (no stage configured at all, a credential you don't have) → one ask_user question with concrete options, not a need_revision the developer cannot act on.

Red Flags

  • A connection string or base URL in your commands points at prod → stop immediately.
  • "I'll just check this one thing on prod" → no. Preview, local or stage, always.
  • Testing a preview or stage whose commit is not the PR head → the verdict describes an earlier version.

리뷰

아직 리뷰가 없습니다. 사용해 본 소감을 남겨 주세요.

댓글

로그인 없이 쓸 수 있습니다. 사용 후기, 질문, 작동하지 않은 환경 등을 편하게 남겨 주세요.

아직 댓글이 없습니다. 첫 댓글을 남겨 보세요.

보내면 바로 공개됩니다. 이메일 주소나 전화번호 같은 개인 정보는 쓰지 마세요. URL은 2개까지입니다.

0 / 1,000자

이 양식은 reCAPTCHA로 보호되며 Google 개인정보처리방침 및 서비스 약관이 적용됩니다.

같은 저장소의 스킬

Use when writing acceptance criteria for a task - express each as an observable Given/When/Then that QA can execute, including negative cases

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

makifbaysal/tasktrooper1172026년 10월 21일 업데이트

Use when the diff adds or changes an endpoint, resolver, RPC, job or query that takes an object id, a role check, a request binding or a tenant filter - BOLA/IDOR, function-level authorization, mass assignment and tenant scoping

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

makifbaysal/tasktrooper1172026년 10월 21일 업데이트

Use on every UI change - semantic HTML, labels for controls, keyboard-navigable dialogs/menus, visible focus, and never color as the only signal

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

makifbaysal/tasktrooper1172026년 10월 21일 업데이트

Use when a task changes any screen, form, dialog, menu or control - Lighthouse/axe scan of the changed screens, a keyboard walk, and the thresholds that fail a task

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

makifbaysal/tasktrooper1172026년 10월 21일 업데이트

How to work a task returned with review, QA or UAT findings. Use when a task is in need_revision or PR review comments are in your context.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

makifbaysal/tasktrooper1172026년 10월 21일 업데이트

Use when the repository keeps its alerting in code, or a person asks for alerts outside TaskTrooper - PrometheusRule YAML, a Cloud Monitoring alert policy in Terraform, a Datadog monitor, each routed to TaskTrooper's alert ingest URL so it opens an incident here

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

makifbaysal/tasktrooper1172026년 10월 21일 업데이트

makifbaysal의 스킬 모두 보기

이 스킬의 문제 신고