How It Works
TestivAI integrates seamlessly with your existing test framework through a simple function call. No complex dependencies required.
Simple Integrationโ
// In your test
testivaiWitness('homepage-test')
// That's it! TestivAI handles the rest
TestivAI captures visual snapshots and analyzes them for regressions, all without modifying your test logic.
Framework Supportโ
TestivAI works with all major test frameworks:
- Cypress
- Playwright
- Selenium
- WebdriverIO
- Puppeteer
- And more...
No framework lock-in - use what works for your team.
Smart Analysisโ
TestivAI's unique 5-layer analysis system catches visual bugs while minimizing false positives:
| Layer | What it Checks | Why it Matters |
|---|---|---|
| 1. DOM Structure | Page structure integrity | Detects missing or broken elements |
| 2. CSS Styles | Visual styling differences | Catches color, font, and style regressions |
| 3. Layout Positions | Element positioning | Flags layout shifts and misalignments |
| 4. Perceptual | What users actually see | Filters out meaningless visual noise |
| 5. AI Counselor | Intelligent change analysis | Explains if changes are bugs or features |
This multi-layer approach ensures only meaningful visual changes are flagged for review.
Chrome Setupโ
Chrome must start with --remote-debugging-port=9222. The testivai init wizard adds this automatically for supported frameworks:
- Cypress: Injects via
cypress.config.jssetupNodeEventsplugin - Selenium: Adds
ChromeOptionsarg in the generated helper file - WebdriverIO: Documents the
goog:chromeOptionsconfig - Puppeteer: Adds
--remote-debugging-port=9222topuppeteer.launch()args
Baseline Managementโ
First test run โ Creates baseline
Future runs โ Compared against baseline:
No changes โ Test passes
Changes found โ Analyzed for impact
Needs review โ Flagged for your attention