<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Nilmini Dharmakeerthi on Medium]]></title>
        <description><![CDATA[Stories by Nilmini Dharmakeerthi on Medium]]></description>
        <link>https://medium.com/@nilmini.dharmakeerthi?source=rss-676728dc3844------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*NT53yJlgat0_dS5EsBSxog.jpeg</url>
            <title>Stories by Nilmini Dharmakeerthi on Medium</title>
            <link>https://medium.com/@nilmini.dharmakeerthi?source=rss-676728dc3844------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Wed, 18 Nov 2026 14:43:01 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@nilmini.dharmakeerthi/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Data-First Test Automation Script Writing]]></title>
            <link>https://medium.com/@nilmini.dharmakeerthi/data-first-test-automation-script-writing-4c58cdd4a711?source=rss-676728dc3844------2</link>
            <guid isPermaLink="false">https://medium.com/p/4c58cdd4a711</guid>
            <category><![CDATA[data-first-testing]]></category>
            <category><![CDATA[software-testing]]></category>
            <category><![CDATA[playwright-test]]></category>
            <category><![CDATA[quality-assurance]]></category>
            <category><![CDATA[ai]]></category>
            <dc:creator><![CDATA[Nilmini Dharmakeerthi]]></dc:creator>
            <pubDate>Sun, 13 Sep 2026 17:24:44 GMT</pubDate>
            <atom:updated>2026-09-13T17:24:44.261Z</atom:updated>
            <content:encoded><![CDATA[<p>AI is becoming increasingly useful in test automation. It can generate Playwright, Selenium, Cypress, or API automation scripts quickly from plain-language requirements. However, when AI is given only a requirement, it often has to guess missing details.</p><p>That is where <strong>Data-First AI automation</strong> becomes important.</p><p>The key idea is simple:</p><p><em>AI should generate the automation logic, but the important values should come from trusted, structured test data.</em></p><p>This reduces hallucination, improves script accuracy, and makes automation easier to maintain.</p><h3><strong>Traditional AI Test Automation</strong></h3><p>In traditional AI-based automation, the user may provide only a simple requirement.</p><p>Requirement<br>↓<br>AI<br>↓<br>Automation Script</p><p>Example requirement:</p><p>“Verify successful login with valid credentials.”</p><p>The AI may generate a script (Playwright- Type script code) like this:</p><p><em>test(‘User can login’, async ({ page }) =&gt; {<br>await page.getByRole(‘textbox’, { name: ‘Username’ }).fill(‘John’);<br>await page.getByRole(‘textbox’, { name: ‘Password’ }).fill(‘Password123’);<br>await page.getByRole(‘button’, { name: ‘Login’ }).click();<br>await expect(page).toHaveURL(/dashboard/);<br>});</em></p><p>At first glance, this script looks correct. It has a login test, fills in credentials, clicks the login button, and validates the dashboard URL.</p><p>But there is a major problem:<strong> the AI invented many details.</strong></p><p>It guessed the username, password, locator names, expected URL, and business behavior.</p><h4>Problems With Requirement-Only AI Automation</h4><p>When AI receives only a requirement, it may produce code that looks professional but tests the wrong thing.</p><p>1. AI May Invent Test Data</p><p>AI may create fake usernames, passwords, VINs, prices, dates, IDs, or customer records.</p><p>For example:</p><p>```<br>.fill(‘John’)<br>.fill(‘Password123’)<br>```</p><p>These values may not exist in the QA or staging environment. The test will fail, not because the application is broken, but because the test data is invalid.</p><p>2. Incorrect Locators</p><p>AI may guess selectors such as:</p><p>```<br>getByRole(‘button’, { name: ‘Login’ })<br>getByRole(‘textbox’, { name: ‘Username’ })<br>```</p><p>These may not match the real application. The actual field could be labeled `Email`, `User ID`, or use a custom component without proper accessibility roles.</p><p>3. Hallucinated Application Behavior</p><p>AI may assume that a page, field, button, API, or workflow exists.</p><p>For example, it may assume:</p><p>```<br>Login redirects to /dashboard<br>```<br>But the actual application may redirect to `/home`, `/account-summary`, or a role-based landing page.</p><p>4. Poor Understanding of Business Rules</p><p>AI may not understand application-specific rules from a short requirement.</p><p>For example:</p><p>```<br>Agreed amount should not be editable.<br>```</p><p>If this rule is not provided clearly, AI may generate a test that edits the field instead of verifying that it is disabled.</p><p>5. Environment Dependency</p><p>A script generated for one environment may fail in another.</p><p>QA, staging, and production-like environments can have different:</p><p>- URLs<br>- users<br>- permissions<br>- feature flags<br>- test data<br>- configurations</p><p>Hardcoded assumptions make tests fragile.</p><p>6. More Maintenance</p><p>If test data is hardcoded inside scripts, every data change requires code changes.</p><p>When UI elements, credentials, expected messages, or business rules change, many AI-generated tests may need modification.</p><p>7. Duplicate and Inconsistent Scripts</p><p>AI may generate different coding styles for similar test cases.</p><p>One script may use `getByRole`, another may use CSS selectors, and another may use XPath. Over time, this creates an inconsistent and hard-to-maintain automation framework</p><p>8. Security Risks</p><p>Sensitive credentials or production data may accidentally be included in prompts or generated scripts.</p><p>Automation should avoid exposing real secrets. Credentials should come from secure test-data management, environment variables, or secret stores.</p><p>9. Correct-Looking Code Can Still Be Wrong</p><h4>This is one of the biggest risks.</h4><p>The generated code may be syntactically valid and look clean, but it may validate the wrong behavior, use wrong data, or miss the actual business rule.</p><h3>What Is Data-First AI Automation?</h3><p>Data-First AI automation changes the flow.</p><p>Instead of asking AI to invent the missing information, we first provide structured and trusted data.</p><p>```<br>Data-First AI Automation</p><p><strong>Requirement<br>↓<br>Structured Test Data<br>↓<br>Test Case + Locator + Environment Data<br>↓<br>AI<br>↓<br>Automation Script<br>↓<br>Validation<br>↓<br>Execution</strong></p><p>```<br>In this approach, AI does not start with only a vague requirement. It receives useful context such as:</p><p><em>- test case ID<br>- scenario name<br>- application URL<br>- test data<br>- expected result<br>- browser<br>- device<br>- environment<br>- locator information<br>- business rules</em></p><p>Example Structured Test Data</p><p>Instead of this:</p><p>```<br>Verify successful login with valid credentials.</p><p>```</p><p>We provide structured data like this:</p><p>```json</p><p>{<br><em>“testCaseId”: “LOGIN_TC_ID_001”,<br>“scenario”: “Login with valid credentials”,<br>“url”: “/login”,<br>“username”: “sampleUser@example.com”,<br>“password”: “Test@123”,<br>“expectedUrl”: “/dashboard”,<br>“expectedText”: “Dashboard”,<br>“browser”: “chromium”,<br>“device”: “iPhone 13”</em><br>}<br>```<br>Now AI has trusted input. It does not need to invent credentials, URLs, browser type, device, or expected result.</p><h4>AI-Generated Playwright Script Using Data-First Approach</h4><p>```ts</p><p>import { test, expect, devices } from ‘@playwright/test’;<br>const testData = {<br>testCaseId: ‘LOGIN_TC_ID_001’,<br>scenario: ‘Login with valid credentials’,<br>url: ‘/login’,<br>username: ‘sampleUser@example.com’,<br>password: ‘Test@123’,<br>expectedUrl: ‘/dashboard’,<br>expectedText: ‘Dashboard’,<br>browser: ‘chromium’,<br>device: ‘iPhone 13’<br>};</p><p>test.use({<br>…devices[testData.device],<br>browserName: testData.browser<br>});</p><p>test(`${testData.testCaseId} — ${testData.scenario}`, async ({ page }) =&gt; {<br>await page.goto(testData.url);<br>await page.getByRole(‘textbox’, { name: ‘Username’ }).fill(testData.username);<br>await page.getByRole(‘textbox’, { name: ‘Password’ }).fill(testData.password);<br>await page.getByRole(‘button’, { name: ‘Login’ }).click();<br>await expect(page).toHaveURL(new RegExp(testData.expectedUrl));<br>await expect(page.getByText(testData.expectedText)).toBeVisible();<br>});<br>```</p><p>This version is better because the test values come from structured data, not from AI assumptions.</p><p>In a real framework, the test data would usually be stored separately in JSON, YAML, CSV, a database, or a test-management system. Sensitive values such as passwords should be handled through secure configuration or secret management.</p><h4>Benefits of Data-First AI Automation</h4><p>1. Reduces Hallucination</p><p>AI receives actual test information instead of inventing usernames, URLs, buttons, or expected results.</p><p>2. Improves Script Accuracy</p><p>The generated script is based on predefined test data and expected behavior, making it more aligned with the real application.</p><p>3. Makes Test Data Reliable</p><p>Test data can be reviewed, approved, and maintained separately from automation code</p><p>4. Improves Locator Quality</p><p>If trusted locator data is provided, AI is less likely to guess incorrect selectors.</p><p>Example:</p><p>```json</p><p>{<br>“locators”: {<br>“username”: “getByRole(‘textbox’, { name: ‘Username’ })”,<br>“password”: “getByRole(‘textbox’, { name: ‘Password’ })”,<br>“loginButton”: “getByRole(‘button’, { name: ‘Login’ })”<br>}<br>}</p><p>```</p><p>5. Supports Multiple Devices</p><p>The same test can run on different devices by changing data.</p><p>```json<br>{<br>“device”: “iPhone 13”<br>}<br>```<br>6. Supports Multiple Browsers<br>The browser can also be data-driven.<br>```json<br>{<br>“browser”: “chromium”<br>}<br>```<br>The same test logic can run on Chromium, Firefox, and WebKit.</p><p>7. Easier Maintenance</p><p>When test data changes, you update the data file instead of rewriting the automation script.</p><p>8. Better Reusability</p><p>The same automation logic can run with multiple datasets.</p><p>For example:</p><p><em>- valid login<br>- invalid login<br>- locked user login<br>- expired password login<br>- role-based login</em></p><p>9. More Consistent Framework Design</p><p>AI can follow the same framework pattern when structured data is consistent.<br>This reduces duplicate scripts and inconsistent coding styles.</p><p>10. Better Scalability</p><p>Hundreds of test cases can be generated from structured test data, especially when combined with page objects, locator repositories, and reusable test templates.</p><h3>Data-First AI in a Playwright Framework</h3><p>This approach is especially useful for an AI + Playwright automation framework.</p><p>A mature data-first framework can include:</p><p>```text<br>requirements<br>test cases<br>test data<br>locator data<br>environment data<br>business rules<br>AI prompt template<br>script generation<br>validation<br>execution<br>reporting<br>```</p><p>For example:</p><p>```text<br><strong>Test Case Data<br>↓<br>Locator Repository<br>↓<br>Environment Config<br>↓<br>Business Rules<br>↓<br>AI Script Generator<br>↓<br>Playwright Test</strong><br>```</p><p>This allows AI to generate automation scripts with better context and fewer wrong assumptions.</p><h4>Better Data-First Structure Example</h4><p>A stronger structured input could look like this:</p><p>```json</p><p>{</p><p>“testCaseId”: “LOGIN_TC_ID_001”,<br>“scenario”: “Login with valid credentials”,<br>“module”: “Authentication”,<br>“environment”: “QA”,<br>“url”: “/login”,<br>“browser”: “chromium”,<br>“device”: “iPhone 13”,<br>“testData”: {<br>“username”: “sampleUser@example.com”,<br>“passwordSecretKey”: “QA_LOGIN_PASSWORD”<br>},</p><p>“locators”: {<br>“usernameInput”: {<br>“strategy”: “role”,<br>“role”: “textbox”,<br>“name”: “Username”<br>},<br>“passwordInput”: {<br>“strategy”: “role”,<br>“role”: “textbox”,<br>“name”: “Password”<br>},<br>“loginButton”: {<br>“strategy”: “role”,<br>“role”: “button”,<br>“name”: “Login”<br>}<br>},<br>“expectedResult”: {<br>“urlContains”: “/dashboard”,<br>“visibleText”: “Dashboard”<br>}<br>}</p><p>```</p><p>This is better because it separates:</p><p><em>- test case information<br>- environment<br>- test data<br>- locators<br>- expected results<br>- secret references</em></p><p>The AI can now generate a script based on trusted inputs instead of guessing.</p><p><strong><em>Traditional AI vs Data-First AI</em></strong></p><p>Traditional AI asks: What script should I write?</p><p>Data-First AI gives AI the trusted context needed to decide: What script should I write using this approved data, these locators, this environment, and these expected results?</p><p>That difference is important.</p><p><em>Traditional AI may create a script that looks correct.</em></p><p><em>Data-First AI is more likely to create a script that is actually useful, maintainable, and executable in the target environment.</em></p><h3>Conclusion</h3><p>Data-First Test Automation Script Writing is a more reliable way to use AI in automation.</p><p>Instead of giving AI only a requirement and allowing it to guess missing details, we first provide structured test data, locator information, environment configuration, and expected results.</p><p>This helps reduce hallucination, improve accuracy, protect sensitive data, and create scalable automation scripts.</p><p>For AI-based Playwright automation, the best approach is:</p><p>AI generates the automation logic.<br>Trusted structured data provides the values.<br>Validation confirms the generated script is correct.<br>Execution proves the test works in the target environment.</p><p>In short:</p><p>**Do not let AI invent critical test details. Give AI trusted data first, then let it generate the automation script.**</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=4c58cdd4a711" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Choosing the Right AI Model for Test Automation]]></title>
            <link>https://medium.com/@nilmini.dharmakeerthi/choosing-the-right-ai-model-for-test-automation-f900b376ddd4?source=rss-676728dc3844------2</link>
            <guid isPermaLink="false">https://medium.com/p/f900b376ddd4</guid>
            <category><![CDATA[ai-model]]></category>
            <category><![CDATA[quality-assurance]]></category>
            <category><![CDATA[ai]]></category>
            <category><![CDATA[ai-based-testing]]></category>
            <category><![CDATA[software-testing]]></category>
            <dc:creator><![CDATA[Nilmini Dharmakeerthi]]></dc:creator>
            <pubDate>Wed, 12 Aug 2026 17:16:50 GMT</pubDate>
            <atom:updated>2026-08-12T17:16:50.995Z</atom:updated>
            <content:encoded><![CDATA[<p>When working with AI tools, model selection is very important. Choosing the right model helps us get <strong>accurate</strong>, <strong>fast</strong>, <strong>relevant</strong>, and <strong>cost-effective</strong> results. If we use AI models without understanding their capabilities and features, the output may be misleading, and it can also increase unnecessary cost.</p><p>We do not need to depend on only one AI model. We also do not need to use the same model for every task. Instead, we should select the model based on the requirement, complexity, and expected outcome.</p><p>Before selecting a model, we should clearly understand the task. For example, in test automation, we need to consider:</p><p><strong>- How many test steps need to be covered in the script?<br>- Is the test case simple or complex?<br>- Does the test require deep reasoning?<br>- Is there a large amount of code or documentation to analyze?<br>- Do we need fast output, or do we need highly accurate output?</strong></p><p>When we talk about test automation with AI, complex and lengthy test cases need more capable models. If a test case has many steps, multiple validations, complex logic, or a large codebase, we should select a model with strong reasoning ability, good coding capability, and a large context window. These models can understand the full scenario better and generate more reliable automation scripts.</p><p>However, not every task requires a high-capacity model. If we only need to identify a small piece of code, find specific information, summarize a simple function, or make a minor change, we can use a faster and lower-cost model. In such cases, using a reasoning model with a large context window may consume more tokens and increase cost without adding much value.</p><p>For example, if we face a complex coding issue in test automation and need to think deeply about the root cause, framework design, test data handling, or reusable functions, then a reasoning model with a high context window is a better choice. But for simple tasks like locating an element, rewriting a small assertion, or checking syntax, a lighter model is usually enough.</p><p>In summary, the best approach is to match the AI model to the task. Simple tasks should use fast and cost-effective models. Complex tasks should use advanced models with strong reasoning, coding ability, and larger context capacity. This helps us improve accuracy, save time, and avoid unnecessary cost while working with AI in test automation.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=f900b376ddd4" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Prompt Engineering for QA Engineers Moving Toward Agentic QA]]></title>
            <link>https://medium.com/@nilmini.dharmakeerthi/prompt-engineering-for-qa-engineers-moving-toward-agentic-qa-8b047c1bef7a?source=rss-676728dc3844------2</link>
            <guid isPermaLink="false">https://medium.com/p/8b047c1bef7a</guid>
            <category><![CDATA[test-automation]]></category>
            <category><![CDATA[prompt-engineering]]></category>
            <category><![CDATA[ai]]></category>
            <category><![CDATA[software-testing]]></category>
            <category><![CDATA[ai-based-testing]]></category>
            <dc:creator><![CDATA[Nilmini Dharmakeerthi]]></dc:creator>
            <pubDate>Mon, 10 Aug 2026 18:34:28 GMT</pubDate>
            <atom:updated>2026-08-10T18:34:28.411Z</atom:updated>
            <content:encoded><![CDATA[<p>Artificial Intelligence is becoming a powerful assistant for QA engineers. It can help generate test cases, analyze requirements, identify gaps, create regression scenarios, and even convert manual test cases into automation scripts.</p><p>However, AI gives useful results only when we give it clear instructions. This is where prompt engineering becomes important.</p><p>Prompt engineering means creating clear, specific, and effective instructions for an AI model so that it can produce the desired result. In simple words, it is learning how to communicate with AI effectively.</p><p>For QA engineers who want to move toward agentic QA, prompting is an essential skill.</p><h4><strong>1.Key Elements of Prompt Engineering</strong></h4><p>1. <strong>Role</strong>: Tell the AI who it should act as.</p><p>Example: <br>&gt; Act as a Senior Quality Assurance Engineer.</p><p>This helps the AI respond from the correct perspective.</p><p>2. <strong>Context </strong>:Give relevant background about the application, feature, or requirement.</p><p>Example: <br>&gt; We are testing the login page of a web application.</p><p>Context helps the AI understand the business and technical scope.</p><p>3. <strong>Task</strong>: ‘Clearly define what you want the AI to do.’</p><p>Example: <br>&gt; Generate positive, negative, security, device, and browser test scenarios.</p><p>A clear task reduces confusion and improves output quality.</p><p>4. <strong>Constraints </strong>: Define limitations and rules.</p><p>Example: <br>&gt; Limit the output to 10 test cases.<br>&gt; Do not assume functionality that is not mentioned.<br>&gt; Generate manual test cases only.</p><p>Constraints help control the scope and prevent unwanted output.</p><p>5. <strong>Output Format</strong> : ‘Tell the AI how to respond.’</p><p>Example: <br>&gt; Return the result with Test Case ID, Scenario, Preconditions, Steps, Test Data, and Expected Result.<br>&gt; Store the output under the output folder using the Jira ticket ID as the file name.<br>&gt; A defined output format makes the result easier to review, reuse, and maintain.</p><h4><strong>2.Why Prompting Matters in QA</strong></h4><p>A weak prompt gives weak results.</p><p>For example:</p><p><em>‘Write test cases’</em></p><p>This prompt is too broad. The AI does not know:</p><p>- What application is being tested?<br>- Which feature should be covered?<br>- How many test cases are needed?<br>- What type of testing is required?<br>- What format should be used?<br>- Should the result be stored anywhere?<br>- Should the test cases be manual or automation-ready?</p><p>Because the instruction is unclear, the AI may generate generic and incomplete test cases.</p><p>A better prompt provides role, context, task, constraints, input, and expected output format.</p><h4>3.Sample Prompts</h4><p>Example Prompt for Manual Test Case Generation</p><p>‘<em>ROLE</em></p><p>You are a Senior QA Engineer and Test Analyst with strong experience in functional testing, UI testing, API testing, integration testing, regression testing, and test design techniques.</p><p><em>CONTEXT</em></p><p>I will provide a Jira ID, Jira description, acceptance criteria, and related documents, functional specifications, technical specifications, UI/Figma documentation, API documentation, business rules, and existing test documentation.</p><p><em>TASK</em></p><p>Generate comprehensive manual QA test cases for the provided Jira ticket.</p><p>Analyze:</p><p>- Jira description<br>- Acceptance criteria<br>- Business rules<br>- Functional requirements<br>- UI requirements<br>- API requirements<br>- Dependencies<br>- Expected behavior<br>- Impacted modules</p><p>Create test scenarios covering:</p><p>- Positive scenarios<br>- Negative scenarios<br>- Functional scenarios<br>- UI scenarios<br>- Field validations<br>- Boundary values<br>- Empty or null values<br>- Invalid inputs<br>- Error handling<br>- User roles and permissions<br>- API or integration scenarios<br>- Regression impact</p><p><em>CONSTRAINTS</em></p><p>- Treat Jira and related documents as the source of truth.<br>- Do not assume functionality that is not specified.<br>- Do not invent business rules, validations, roles, workflows, or error messages.<br>- Highlight conflicts between Jira and related documents.<br>- Avoid duplicate test cases.<br>- Generate manual QA test cases only.<br>- Prioritize test cases as High, Medium, or Low.</p><p><em>OUTPUT FORMAT</em></p><p>1. Requirement Summary<br>2. Assumptions and Requirement Gaps<br>3. Test Scenarios<br>4. Detailed Test Cases<br>5. Acceptance Criteria Coverage<br>6. Negative and Edge Cases<br>7. Regression Impact<br>8. Final QA Summary</p><p>INPUT</p><p>Jira ID: [JIRA-ID]<br>Related Documents: [Paste or attach documents here]<br>Jira Description / Acceptance Criteria: [Paste Jira details here]’</p><p>This prompt gives the AI enough information to generate structured, useful, and reviewable QA test cases.</p><p><strong>Prompting for QA Automation</strong></p><p>Prompt engineering is also useful when converting manual test cases into automation scripts.</p><p>For example, if your project uses Playwright and TypeScript, the prompt should explain the framework, coding standards, folder structure, and expectations.</p><p>Example: Prompt for Playwright Automation Script Generation</p><p>‘<em>ROLE</em></p><p>You are a Senior QA Automation Engineer specializing in Playwright, TypeScript, test automation architecture, and Page Object Model.</p><p><em>CONTEXT</em></p><p>I will provide one or more manual test cases. Your job is to convert them into Playwright automation scripts within the existing automation framework.</p><p>The project uses:</p><p>- Playwright<br>- TypeScript<br>- Page Object Model<br>- Playwright Test<br>- Existing fixtures, utilities, test data, and helper functions</p><p>Before generating code, inspect the existing project structure and reuse existing code wherever possible.</p><p><em>TASK</em></p><p>Convert the provided manual test cases into Playwright automation scripts.</p><p>For each test case:</p><p>- Understand the objective and expected behavior.<br>- Map manual steps to Playwright actions.<br>- Convert expected results into assertions using expect().<br>- Reuse existing Page Objects, locators, fixtures, and utilities.<br>- Create or update Page Objects only when required.<br>- Keep each test independent and maintainable.</p><p><em>CONSTRAINTS</em></p><p>- Use Playwright with TypeScript.<br>- Follow the existing Page Object Model structure.<br>- Do not introduce a different framework.<br>- Prefer reliable locators such as getByRole(), getByLabel(), getByPlaceholder(), and getByText().<br>- Avoid unnecessary page.waitForTimeout().<br>- Do not hard-code credentials or sensitive data.<br>- Do not modify unrelated files.<br>- Do not create tests without assertions.</p><p><em>OUTPUT FORMAT</em></p><p>1. Test Case Information<br>2. Existing Code Reuse<br>3. Required Changes<br>4. Playwright Automation Code<br>5. Validation Mapping<br>6. Implementation Summary<br>7. Automation Gaps</p><p>MANUAL TEST CASES</p><p>[Paste manual test cases here]’</p><p>This type of prompt helps the AI generate automation code that fits the existing framework instead of producing random or disconnected scripts.</p><h4><strong>4.Benefits of Good Prompting for QA Engineers</strong></h4><p>Good prompts help QA engineers:</p><p>Generate better manual test cases<br>- Improve requirement analysis<br>- Identify missing acceptance criteria<br>- Find requirement gaps and conflicts<br>- Create negative and edge test scenarios<br>- Improve regression coverage<br>- Convert manual test cases into automation scripts<br>- Save time during test design<br>- Maintain consistency in QA deliverables</p><h4>5.Final Thoughts</h4><p>Prompting is not just about asking AI to do something. It is about giving the AI the right role, context, task, constraints, and output expectations.</p><p>For QA engineers moving toward agentic QA, prompt engineering is a must-have skill. A clear prompt can turn AI into a useful QA assistant that helps with requirement analysis, test case design, automation planning, and test coverage improvement.</p><p>The better the prompt, the better the result.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=8b047c1bef7a" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Fast Cross-Browser and Device Testing with Cursor AI and Playwright]]></title>
            <link>https://medium.com/@nilmini.dharmakeerthi/fast-cross-browser-and-device-testing-with-cursor-ai-and-playwright-932b48454f74?source=rss-676728dc3844------2</link>
            <guid isPermaLink="false">https://medium.com/p/932b48454f74</guid>
            <category><![CDATA[cursor-ai]]></category>
            <category><![CDATA[device-testing]]></category>
            <category><![CDATA[cross-browser-testing]]></category>
            <category><![CDATA[software-testing]]></category>
            <category><![CDATA[ai-based-testing]]></category>
            <dc:creator><![CDATA[Nilmini Dharmakeerthi]]></dc:creator>
            <pubDate>Fri, 07 Aug 2026 12:40:01 GMT</pubDate>
            <atom:updated>2026-08-07T12:48:50.615Z</atom:updated>
            <content:encoded><![CDATA[<p><strong>1.Overview</strong></p><p>QA engineers often spend significant time testing the same feature across different browsers and devices. This increases the testing effort and can delay product delivery to the client.</p><p>To reduce this effort, we can use Cursor AI with Playwright automation. Playwright supports cross-browser testing, device emulation, and parallel execution. By combining Playwright with Cursor AI rules, skills, and commands, QA teams can generate test plans, create automation scripts, refine failing scripts, and produce test case documentation faster.</p><p>This approach helps improve test coverage while reducing manual testing time.</p><p><strong>Playwright Browser Testing Capability</strong></p><p>Playwright supports all major browser engines, allowing QA teams to verify that the application behaves consistently across different browsers. Using Playwright, the same automation script can be executed across multiple browsers. This helps identify browser-specific UI, functional, or compatibility issues early.</p><p><strong>Playwright Device Testing Capability</strong></p><p>Playwright supports device testing through browser-based emulation. It can simulate device characteristics such as:</p><p>-Screen size<br>- Viewport<br>- Touch support<br>- User agent<br>- Device scale factor<br>- Mobile browser behavior</p><p>Playwright provides many predefined device profiles through its `devices` configuration. This allows QA teams to test mobile and tablet behavior without needing every physical device.</p><p>Examples include:</p><p>- iPhone<br>- iPad<br>- Pixel devices<br>- Android tablets<br>- Desktop browsers</p><p>If specific devices are required, they can be mentioned in the requirement or test plan, and Cursor AI can generate test scenarios and automation scripts accordingly.</p><p><strong>2. Proposed QA Automation Flow</strong></p><p><em>2.1. Test Plan Generation</em></p><p>A Cursor command can be created to generate QA test plans from requirements, Jira stories, screenshots, or feature notes.</p><p>The test plan generation command should include:</p><p>- Functional test scenarios<br>- Browser compatibility coverage<br>- Device testing coverage<br>- Positive and negative test cases<br>- UI validation<br>- Security testing points<br>- Performance considerations<br>- Regression testing scope</p><p>The related Cursor skill file should define the detailed workflow for generating Playwright-focused QA test plans. It should ensure that browser and device testing are considered during test planning. If the requirement mentions specific browsers or devices, the generated test plan should include those explicitly.</p><p><em>2.2. Test Script Generation</em></p><p>After the test plan is generated, another Cursor command can be used to create Playwright automation scripts from the test plan.</p><p>The script generation command should focus on:</p><p>- Converting test plan into Playwright tests<br>- Adding browser compatibility coverage<br>- Adding device emulation coverage<br>- Using Playwright projects for multiple browsers/devices<br>- Following the existing framework structure<br>- Creating reusable locators and page objects where required</p><p>The related skill file should explain how Cursor AI should generate Playwright scripts for browser and device testing. This helps Cursor AI create automation scripts faster while still considering the required coverage</p><p><em>2. 3. Script Execution and Refinement</em></p><p>After scripts are generated, a refinement command can be used to execute and stabilize the tests.</p><p>This command should:</p><p>- Run the generated Playwright tests<br>- Identify failures<br>- Debug locator, timing, or assertion issues<br>- Fix flaky tests<br>- Re-run failed tests<br>- Validate browser and device execution<br>- Ensure the final script is stable</p><p>Playwright also supports parallel execution, which helps run many tests across multiple browsers and devices within a short time. This is especially useful during regression testing, where many test cases need to be executed quickly.</p><p><em>2 .4.AIO Test Case Documentation</em></p><p>After automation scripts are validated, Cursor AI can also help generate formal QA test case documentation.</p><p>The generated test cases can be exported into:</p><p>- CSV<br>- Excel<br>- Markdown</p><p>These test cases can then be uploaded into AIO Test Management.</p><p>After AIO test cases are created, the generated AIO test case IDs can be added back into the automation code for traceability.</p><p>Cursor AI can also be configured with:</p><p>- AIO project ID<br>- AIO cycle ID<br>- Test case IDs<br>- Execution mapping details</p><p>When the Playwright scripts are executed, results can be updated against the relevant AIO test cases and cycles if integration support is configured.</p><p><strong>3. Benefits</strong></p><p>Using Cursor AI with Playwright for browser and device testing provides several benefits:</p><p>-Reduces repeated manual testing effort<br>- Speeds up browser compatibility testing<br>- Supports device testing through emulation<br>- Improves test coverage<br>- Enables faster regression execution<br>- Helps generate test plans and automation scripts quickly<br>- Supports structured QA documentation<br>- Improves delivery speed<br>- Reduces risk of browser or device-specific defects</p><p><strong>4. Conclusion</strong></p><p>By configuring Cursor AI with proper rules, skills, and commands, QA teams can build a faster and more reliable Playwright automation workflow.</p><p>This workflow supports:</p><p>1. Requirement-based test plan generation.<br>2. Browser and device-focused automation script creation.<br>3. Script execution and refinement.<br>4. Parallel regression testing.<br>5. AIO-compatible test case documentation.</p><p>This approach helps QA engineers complete browser and device testing in less time while maintaining strong test coverage and supporting faster product delivery.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=932b48454f74" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Reducing AI Costs with Cursor AI: Token Optimization Tips for QA Engineers]]></title>
            <link>https://medium.com/@nilmini.dharmakeerthi/reducing-ai-costs-with-cursor-ai-token-optimization-tips-for-qa-engineers-99b6965faa3c?source=rss-676728dc3844------2</link>
            <guid isPermaLink="false">https://medium.com/p/99b6965faa3c</guid>
            <category><![CDATA[token]]></category>
            <category><![CDATA[cost-cutting]]></category>
            <category><![CDATA[ai-testing]]></category>
            <category><![CDATA[software-testing]]></category>
            <category><![CDATA[ai-best-practices]]></category>
            <dc:creator><![CDATA[Nilmini Dharmakeerthi]]></dc:creator>
            <pubDate>Fri, 31 Jul 2026 18:16:06 GMT</pubDate>
            <atom:updated>2026-07-31T18:16:06.710Z</atom:updated>
            <content:encoded><![CDATA[<h3>Token ?</h3><p>A token is a small piece of text that the AI reads and generates. It includes words, punctuation, spaces, and code.</p><p>Tokens are used for:</p><ol><li>Your input</li><li>Project files included as context</li><li>Chat history</li><li>The AI’s response</li></ol><p>Example: If you ask: <em>“Generate Playwright tests for the login feature.”</em> The AI might use:</p><ol><li>Prompt: 20 tokens</li><li>Context (Opened files): 3,000 tokens</li><li>Response: 300 tokens</li><li>Total token count = 3,320 tokens</li></ol><h3>Why do tokens matter?</h3><ol><li>Response speed: They directly affect how fast the AI responds.</li><li>Cost: They impact your Cursor plan’s usage limits, which translates directly to cost.</li><li>Context window limit: Every AI model has a context window (a maximum number of tokens it can process at once). If you exceed it, older context will be dropped and forgotten by the AI.</li></ol><h3>How to Reduce Token Usage</h3><p>1. Open only related files.<br> “Opening only related files” means providing the AI with just the files relevant to the task, instead of giving it your entire project or repository. This reduces token usage, improves response quality, and helps the AI focus on the problem. For example, if you want to debug changes in a specific file, only provide that exact file.</p><p>2. Avoid opening unrelated files. <br>Do not include files that are unneeded for the current task. Every extra file increases the amount of information the AI must process, leading to higher token usage, slower responses, and potentially less accurate answers.</p><p>3. Start a new chat for a new feature. <br>If we use the same chat for unrelated tasks, the AI reads all past chat history, consuming tokens for useless information. If you want to create test plans for multiple epics or tasks, treat them as separate, individual tasks. Start a new chat for each task; otherwise, the AI consumes unnecessary tokens by reading unrelated chat history.</p><p>4. Use Rules, Commands, and Skills files instead of repeating long instructions. <br>Create separate commands for test planning, generating test cases, and writing automation scripts. Also, create separate skill files for specific tasks like test case writing and automation script generation.</p><p>5. Write short prompts.<br>A short prompt is a clear, concise instruction that tells the AI exactly what you want without unnecessary details. Short prompts reduce token usage, produce faster responses, and are easier for the AI to understand.</p><p>6. Ask for one task at a time. <br>Asking for one task at a time means giving the AI a single, clear objective in each prompt instead of combining multiple unrelated tasks into one request. This helps the AI focus, reduces token usage, and improves the accuracy of the response.</p><p>7. Work feature by feature. <br>If you ask the AI to generate an entire application or a complete test suite in one prompt, it has to process a huge amount of information. This can lead to:</p><ul><li>High token usage</li><li>Slower responses</li><li>More mistakes</li><li>Missing requirements</li><li>Harder-to-review output</li></ul><p>By focusing on one feature at a time, the AI can produce more accurate, detailed, and maintainable results.</p><p>8. Limit the output.<br>Without limits, the AI may generate lengthy explanations, include unnecessary examples, repeat information, and consume more tokens. Limiting the output helps ensure faster responses, lower token usage, reduced costs, and improved readability.</p><p>9. Choose the right model. <br>Choosing the right AI model is one of the most important factors in getting good results while controlling costs, speed, and token usage. Different models are optimized for different types of tasks. You should select the model based on your requirements:</p><ul><li>Small models: Provide faster feedback, cost less, and are ideal for simple or repetitive tasks.</li><li>Mid-size models: Can be used for tasks like test case generation.</li><li>Large models: Good for test planning (handling complex analysis), automation script writing, and debugging, as they can better understand complex logic and generate higher-quality code. Using a powerful model is not necessary for every task, as large models cost more, require more compute, and have slower responses.</li></ul><p>Implementing the practices above will help reduce token usage while improving task quality and response speed.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=99b6965faa3c" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Leveraging AI for Efficient Test Planning with Cursor]]></title>
            <link>https://medium.com/@nilmini.dharmakeerthi/leveraging-ai-for-efficient-test-planning-with-cursor-4e08d066c072?source=rss-676728dc3844------2</link>
            <guid isPermaLink="false">https://medium.com/p/4e08d066c072</guid>
            <category><![CDATA[ai-based-testing]]></category>
            <category><![CDATA[test-planning-cursor-ai]]></category>
            <category><![CDATA[software-testing]]></category>
            <category><![CDATA[test-planning]]></category>
            <category><![CDATA[cursor-ai-for-testing]]></category>
            <dc:creator><![CDATA[Nilmini Dharmakeerthi]]></dc:creator>
            <pubDate>Sat, 25 Jul 2026 15:48:59 GMT</pubDate>
            <atom:updated>2026-07-25T15:48:59.655Z</atom:updated>
            <content:encoded><![CDATA[<p>A comprehensive test plan is the most critical first step in the software testing lifecycle. However, creating one manually is time-consuming, as it requires a thorough review of several key areas:</p><p>1.Tasks and Epics (e.g., Jira tickets).<br>2.UI Designs (e.g., Figma files).<br>3.API Documentation.<br>4.Reference Documentations. (e.g., Confluence pages)</p><p>To reduce the time spent on manual review, we can leverage AI. By using Cursor AI, we can automate the generation of test plans while maintaining high quality and accuracy.</p><p><strong>Connecting Your Workflow with MCP</strong></p><p>Cursor uses the <strong>Model Context Protocol (MCP)</strong>, an open standard that allows AI models to integrate with third-party tools. By connecting the relevant MCP servers for Jira, Figma, and API documentation, Cursor can access and analyze your project data in real-time.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*12gZ6WNBGPbwD3KK1O3Rrw.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*aA6winpG-V5UaEaGwSdwCQ.png" /></figure><p><strong>Streamlining with Reusable Commands</strong></p><p>QA engineers often perform similar planning tasks repeatedly. Instead of typing the same prompt for every new ticket, you can use <strong>Commands</strong>. A Command is a reusable prompt that allows you to trigger a test plan workflow instantly without repetitive typing. An example command file has been added. It may vary depending on the project requirements.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*amd6pWyW-FPMs3sK-m1pig.png" /></figure><p><strong>Setting Standards with Rules</strong></p><p>For more granular control, you can define <strong>Rules </strong>in Cursor. Rules are persistent instructions that guide how the AI agent handles tasks. For test planning, these rules should be defined in bullet points to specify formatting preferences, mandatory sections, and output standards. An example Rule file has been added. It may vary depending on the project requirements.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*_fRe4i8G0JuQT_f6p8-O_g.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*AZ2pT41l0SiL6UCfcQPQMA.png" /></figure><p><strong>Formalizing Workflows with Skills</strong></p><p>Complex, multi-step test planning workflows can be added to a <strong>Skill</strong> file. In Cursor, Skill files define reusable workflows that allow the agent to perform more detailed and structured tasks autonomously. An example Skill file has been added. It may vary depending on the project requirements.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*eIH9885pJFTSStCoo5Br8Q.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*VNFFUVHqicXs_qeNPwDDOw.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*DhE55zgMn2uvA1iJ_VEqpg.png" /></figure><p><strong>Organizing Inputs and Outputs</strong></p><p>To ensure a smooth workflow, follow these organizational steps:</p><p>1. Markdown Configuration: Create a separate Markdown file to centralize all relevant links, such as Jira tickets and Figma designs.<br>2. Output Management: Create a dedicated folder to store generated test plans. You can add a Rule to ensure the AI always saves its results in this specific directory</p><p><strong>Generating the AI-Based Test Plan</strong></p><p>Once your environment is set up:</p><p>1. Select the Model: Open a new chat and choose an AI model based on task complexity. For long, complex test plans, select a model with a high context window and high reasoning capabilities.<br>2. Run the Prompt: Reference your Markdown file and trigger your custom test plan Command.<br>3. Verify MCPs: Ensure the necessary MCP servers are enabled before starting.</p><p>After reviewing the inputs, the AI will generate the output. While the AI significantly speeds up the process, <em>manual review remains essential</em>. Use the chat to ask questions or refine the output as needed. This same AI-driven approach can then be extended to generating detailed test cases.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=4e08d066c072" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>