max-locator-sniffer
v1.0.2
Published
a tool to audit playwright locators in a repo, Max finds duplicate locators.
Downloads
147
Readme
Max Locator Sniffer
Max Locator Sniffer is a playful but powerful CLI tool that scans your Playwright test code and sniffs out duplicate locators.
Duplicate locators can lead to brittle, flaky tests. Max helps you catch them early by showing:
- Which locators are duplicated
- Where they appear
- How often they are reused
- A clear severity signal so you know what to fix first
✨ Features
- 🔍 Finds duplicate Playwright locators
- 📁 Shows every file location
- 🔢 Displays usage counts
- ⚠️ Highlights HIGH / MEDIUM / LOW severity
- 🖥 Beautiful CLI table output
- ⚡ Fast scans using glob
📦 Installation
npm install -g max-locator-sniffer🚀 Usage
Scan a folder and all of its contents:
max sniff srcExample Output
Roadmap
- Flaky locator scoring system
- CSS complexity analysis
- JSON output mode
- CI mode (--fail-on high)
Why "Max"?
Inspired by Max the dog from The Grinch, this CLI tool loyally sniffs through your repo, hunting down flaky, duplicated locators so your test suite stays healthy and happy.
MIT © Ian Bridges
