← AI for QA
Field Guide · Prompt Engineering for QA

Become AI-ready as a QA in one day.

One reusable prompt frame at 9 AM, then eight copy-paste recipes until your AI writes QA work you'd actually merge — strategy, plans, cases, data, API tests, automation code, bug reports, and refactors.

1
Day
8
Prompt Recipes
1
Framework
0
Blank Pages
// 09:00 · Warm-up

The R·C·T·F Frame

Every recipe below builds on these four moves. Learn it once — reuse it forever.

R

Role

Tell the model who to be. A persona sets vocabulary, rigor, and defaults.

"Act as a senior SDET with 10 years in test automation."

C

Context

Feed the facts: product, stack, constraints, and the source material to work from.

"App: checkout flow. Stack: React + Node. Here's the story + ACs: …"

T

Task

One verb, one deliverable. Be explicit about coverage and depth.

"Generate test cases for happy, negative, boundary, and edge paths."

F

Format

Pin the shape of the answer so it drops straight into your tools.

"Output as a markdown table: ID, steps, data, expected, priority."

+ Power-ups

Examples — paste 1–2 of your real cases so it matches your house style. Constraints — "no hard waits, max 12 cases". Iterate — "now add negative cases" beats rewriting from scratch.

// The Day

09:00 → 17:00 at a glance

Morning designs the tests. Afternoon builds and ships them.

09Strategy
10Test Plan
11Test Cases
12Test Data
13Lunch
14API Tests
15Automation
16Bug Reports
17Review
Morning · Design the Tests09:00 – 12:00 · think before you automate
09:00STRATEGY01

Test Strategy

Produce a risk-based strategy for the whole release — scope, levels, tooling.

strategy.md
Act as a QA lead. We're building [product/feature] for [users].
Stack: [stack]. Top risks: [risk areas]. Release: [cadence].

Draft a test strategy: scope, test levels (unit → E2E),
types (functional, perf, security, a11y), environments,
entry/exit criteria, tooling, and risk-based priorities.

Format with headings + a risk matrix table.

TIPStart broad, then ask "which risks deserve automation first?"

10:00PLAN02

Test Plan

Produce a sprint-ready plan with scope, schedule, deliverables, and owners.

testplan.md
Act as a senior QA engineer. Feature: [feature].
Acceptance criteria: [paste ACs].
Sprint [sprint], target release [date].

Create a test plan: objectives, in/out of scope,
deliverables, schedule, resources, environments,
test data needs, and a RACI.

Output as markdown with a milestone table.

TIPPaste the real ACs — generic plans come from generic context.

11:00CASES03

Test Cases

Produce detailed cases across happy, negative, boundary and edge paths.

cases.md
Act as a QA analyst. From this story + ACs:
"[paste story + acceptance criteria]"

Generate test cases for happy path, negative,
boundary, and edge cases. For each give: ID, title,
preconditions, steps, test data, expected result, priority.

Output as a markdown table.

TIPFollow up: "list cases you'd skip and why" to surface gaps.

12:00DATA04

Test Data Generation

Produce realistic datasets — valid, boundary, and invalid, ready to load.

data.csv
Generate [N] rows of realistic test data for
[entity] with fields: [field:type, …].

Include valid, boundary, and invalid records, plus
locale and edge cases (nulls, max length, special chars).

Output as CSV + a JSON sample, and
flag which rows are negative cases.

TIPAdd "PII-safe, synthetic only" so nothing real leaks in.

Afternoon · Build & Ship14:00 – 17:00 · turn cases into running code
14:00API05

API Test Scaffolding

Produce runnable API tests from a contract — status, schema, auth.

api.spec
Act as an SDET. Here's the API contract:
[paste OpenAPI / endpoint].

Write tests for [endpoint] covering 2xx/4xx/5xx,
schema validation, auth, and required/optional fields.
Use [pytest+requests / RestAssured / Postman].

Include positive, negative, and contract tests.
Output complete runnable code.

TIPHand it the spec file — it'll infer schemas you'd forget.

15:00AUTOMATION06

Automation Code

Produce Playwright / Selenium tests using the Page Object Model.

e2e.ts
Act as an automation engineer. Convert these
manual cases: "[paste cases]" into
[Playwright (TS) / Selenium (Java)] tests using the
Page Object Model.

Include locators, assertions, setup/teardown, and
data-driven params. Add comments.

Output complete, runnable files.

TIP"Use role/test-id locators, no XPath, no hard waits."

16:00BUGS07

Bug Reports

Produce clean, triage-ready reports from messy repro notes.

bug.md
Turn these raw notes into a bug report:
"[paste notes / logs]".

Include: title, severity, priority, environment,
preconditions, steps to reproduce, expected vs actual,
and an attachments checklist.

Suggest a likely root-cause area.
Format for [Jira / Azure DevOps].

TIPAsk for a one-line title a triager can scan in 2 seconds.

17:00REVIEW08

Review & Refactor

Produce a reliability review — flaky waits, brittle locators, fixes.

review.diff
Review this test code: "[paste code]".

Flag flakiness, hard waits, brittle locators,
missing assertions, and duplication.

Refactor for reliability and readability
(POM, explicit waits, fixtures). Explain each change briefly.

Output the improved code + a review checklist.

TIPEnd the day here — clean tests today save triage tomorrow.

/ GOLDEN RULE 01

Context beats cleverness.

Paste real stories, code, and logs — the model is only as sharp as what you feed it.

/ GOLDEN RULE 02

Never ship unread.

AI drafts; you verify. Run it, check the assertions, own the merge.

Save it. Share it. Use it tomorrow.

New AI-for-QA guides drop here every few weeks. If this was useful, send it to a fellow QA engineer who's wrestling with their test backlog.

By Sreenidhi Rajakrishnan · Automation Architect · AI & Automation