Empower your testing with AI-generated scripts and intelligent self-healing.
AiScripto transforms hand-written test cases into production-grade Playwright tests through multiple coordinated AI agents. The entire process is automated, traceable, and controllable.
You can skip or repeat any stage. For example, if a test passes validation but fails execution, you can proceed directly to healing without re-exploring.
AiScripto supports importing test cases from multiple sources:
✓ Syntax validation
✓ Comments check
✓ Precondition validation
✓ Format normalization
✓ Duplication detection
✓ Relevance analysis
@TC_ID: TC-001 @Title: Create New Order @Author: QA Team @Tags: smoke, order-creation **Preconditions:** - User is logged into the system. - User has order creation permissions **Steps:** Step 1: Navigate to the order management page Expected: Order list is displayed Step 2: Click the "Create New Order" button Expected: Order creation dialog is opened Step 3: Enter "ORD-2024-001" in the "Order Number" field Expected: Number is displayed in the field Step 4: Enter "ABC Corporation" in the "Customer Name" field Expected: Customer name is auto-completed and suggestions are displayed Step 5: Select the first suggested customer Expected: Customer information is automatically filled Step 6: Set the order amount to $10,000 Expected: Amount is displayed correctly Step 7: Click the "Submit" button Expected: Order is created successfully, returns to order list
After validation is complete, AiScripto launches a real browser instance and follows the test case steps to perform actual operations while collecting UI element information.
AI operates the browser according to test steps, interacting with real UI
Capture multiple locator options for each interactive element, prioritizing accessible selectors
Use AI vision models to understand UI layout, colors, text and icons
Store known pages and elements in locator cache to accelerate future tests
After exploration is complete, AiScripto uses the collected UI information to generate Playwright TypeScript code that follows industry best practices.
📄 tests/TC-*.spec.ts
Complete Playwright test specifications
📚 src/pages/*.ts
Page Object Models (POM)
🔗 fixtures/*.ts
Shared fixtures (login, setup, etc)
📊 *.data.json
Parameterized test data
📋 report.json
Execution reports and analysis
import { test, expect } from '@playwright/test';
import { OrderPage } from '../pages/OrderPage';
test.describe('Order Management Test Suite', () => {
let page;
let orderPage: OrderPage;
test.beforeEach(async ({ page: p }) => {
page = p;
orderPage = new OrderPage(page);
// Login to application
await page.goto('https://app.example.com/login');
await page.getByRole('textbox', { name: /Username/ }).fill('testuser');
await page.getByRole('textbox', { name: /Password/ }).fill('password');
await page.getByRole('button', { name: /Login/ }).click();
});
test('TC-001: Create New Order', async () => {
// Step 1: Navigate to Order Management page
await page.goto('https://app.example.com/orders');
await expect(page.getByRole('table')).toBeVisible();
// Step 2: Click Create New Order button
await orderPage.clickCreateButton();
await expect(page.getByRole('dialog')).toBeVisible();
// Step 3-7: Fill form and submit
await orderPage.fillOrderNumber('ORD-2024-001');
await orderPage.fillCustomerName('ABC Corporation');
// ... more steps
// Verify results
await expect(
page.getByText(/Order created successfully/)
).toBeVisible();
});
});
Generated tests are executed using the Playwright test runner. If all pass, congratulations! If any fail, AiScripto automatically performs repair.
Analyze detailed Playwright execution logs and screenshots, pinpoint failure precisely
Use AI vision models to compare expected and actual UI, identify visual changes
Try multiple alternative locators, find most robust choice, improve repair success rate
Learn from locator cache and previous repair records, accelerate repair process
85-95% of test failures can be resolved through automatic repair, with no manual intervention needed
After completing basic tests, you can optionally extract hard-coded test data to JSON files, allowing the same test to execute with multiple data sets.
Before (Hard-coded):
After (Parameterization):
// tests/data/order-creation.data.json
{
"testCases": [
{
"id": "ORD-001",
"orderId": "ORD-2024-001",
"customer": "ABC Corporation",
"amount": 5000,
"expectedStatus": "Successfully established"
},
{
"id": "ORD-002",
"orderId": "ORD-2024-002",
"customer": "XYZ Limited",
"amount": 15000,
"expectedStatus": "Successfully established"
},
{
"id": "ORD-003",
"orderId": "ORD-2024-003",
"customer": "QRS Industries",
"amount": 8500,
"expectedStatus": "Successfully established"
}
]
}
Result: 1 test × 3 data combinations = 3 complete test executions, covering different business scenarios
| Command | Function | When to Use | Output |
|---|---|---|---|
/import |
Import test cases | Add new test cases to system | imported-cases.json |
/validate |
Validate test format | Check test case syntax and completeness | validation-report.json |
/explore |
Explore UI and collect elements | Create new tests or update stale locators | locators.json, screenshots/ |
/generate |
Generate Playwright code | Create executable tests from test cases | tests/TC-*.spec.ts, pages/ |
/execute |
Run tests | Verify generated tests pass | test-results.json, traces/ |
/heal |
Auto-repair failed tests | Fix test failures without re-writing | healed-tests/, healing-report.json |
/parameterize |
Extract and parameterize data | Convert hard-coded data to data-driven | *.data.json, parameterized-tests/ |
/verify |
Final verification | Re-execute with all data combinations | final-verification-report.json |
Below is the typical time expectation for an AiScripto test development cycle:
Describe test steps using intuitive natural language.
AI checks formatting and explores UI in real-time applications.
Generate test code and execute validation immediately.
If failed, AI automatically repairs and re-executes
If needed, extract data and create multiple test scenarios
Traditional Method: 2-3 Hours (Writing + Debugging + Testing)
AiScripto: 3-5 Minutes
Time Saved: 90% ⚡