pw-review
यह क्या करती है
यह स्किल एजेंट से आपकी ब्राउज़र टेस्ट फ़ाइलों को आम गलतियों की सूची से मिलवाती है। यह उन डेवलपर्स के लिए है जो चाहते हैं कि उनके टेस्ट भरोसेमंद और आसानी से संभालने लायक हों।
कब इस्तेमाल करें
- ✓जब आपने अभी नए Playwright टेस्ट लिखे हों और उन्हें जँचवाना हो।
- ✓जब आपके ब्राउज़र टेस्ट बार-बार टूट रहे हों और आपको खराब टेस्ट आदतों का शक हो।
- ✓जब कोड रिव्यू से पहले आप टेस्ट की गुणवत्ता जाँचना चाहते हों।
Skill का लिंक
https://github.com/alirezarezvani/claude-skills/blob/main/engineering-team/playwright-pro/skills/pw-review/SKILL.mdइसे कॉपी करके अपने AI (Claude, ChatGPT या Cursor) में पेस्ट करें और निर्देशों का पालन करने को कहें।
कैसे इस्तेमाल करें
सबसे आसान तरीका: मैसेज कॉपी करके अपने AI में पेस्ट करें। वह skill पढ़कर निर्देशों का पालन करेगा।
पेस्ट करने के लिए तैयार मैसेज
Claude Code, Codex या Cursor के लिए: प्रोजेक्ट फ़ोल्डर में चलाएँ और skill इंस्टॉल हो जाएगी।
SKILL.md डाउनलोड करें और अपने एजेंट के skills फ़ोल्डर में रखें।
AI से क्या माँगें: उदाहरण
“मेरे Playwright टेस्ट की समीक्षा कीजिए और बताइए कि किसमें सुधार चाहिए।”
हर हफ़्ते 5 नई skills, 1 मिनट में पढ़ें।
यह कैसे काम करती है
एजेंट आपकी कॉन्फ़िग और टेस्ट फ़ाइलें पढ़ता है, फिर हर फ़ाइल को anti-pattern की सूची से जाँचता है। नतीजों को गंभीर, चेतावनी और सूचना स्तर में बाँटा जाता है।
तकनीकी सामग्री (मूल SKILL.md)
लेखक का मूल टेक्स्ट, अंग्रेज़ी में, सीधे GitHub से।
Review Playwright Tests
Systematically review Playwright test files for anti-patterns, missed best practices, and coverage gaps.
Input
$ARGUMENTS can be:
- A file path: review that specific test file
- A directory: review all test files in the directory
- Empty: review all tests in the project's
testDir
Steps
1. Gather Context
- Read
playwright.config.tsfor project settings - List all
*.spec.ts/*.spec.jsfiles in scope - If reviewing a single file, also check related page objects and fixtures
2. Check Each File Against Anti-Patterns
Load anti-patterns.md from this skill directory. Check for all 20 anti-patterns.
Critical (must fix):
waitForTimeout()usage- Non-web-first assertions (
expect(await ...)) - Hardcoded URLs instead of
baseURL - CSS/XPath selectors when role-based exists
- Missing
awaiton Playwright calls - Shared mutable state between tests
- Test execution order dependencies
Warning (should fix):
8. Tests longer than 50 lines (consider splitting)
9. Magic strings without named constants
10. Missing error/edge case tests
11. page.evaluate() for things locators can do
12. Nested test.describe() more than 2 levels deep
13. Generic test names ("should work", "test 1")
Info (consider):
14. No page objects for pages with 5+ locators
15. Inline test data instead of factory/fixture
16. Missing accessibility assertions
17. No visual regression tests for UI-heavy pages
18. Console error assertions not checked
19. Network idle waits instead of specific assertions
20. Missing test.describe() grouping
3. Score Each File
Rate 1-10 based on:
- 9-10: Production-ready, follows all golden rules
- 7-8: Good, minor improvements possible
- 5-6: Functional but has anti-patterns
- 3-4: Significant issues, likely flaky
- 1-2: Needs rewrite
4. Generate Review Report
For each file:
## <filename> — Score: X/10
### Critical
- Line 15: `waitForTimeout(2000)` → use `expect(locator).toBeVisible()`
- Line 28: CSS selector `.btn-submit` → `getByRole('button', { name: "submit" })`
### Warning
- Line 42: Test name "test login" → "should redirect to dashboard after login"
### Suggestions
- Consider adding error case: what happens with invalid credentials?
5. For Project-Wide Review
If reviewing an entire test suite:
- Spawn sub-agents per file for parallel review (up to 5 concurrent)
- Or use
/batchfor very large suites - Aggregate results into a summary table
6. Offer Fixes
For each critical issue, provide the corrected code. Ask user: "Apply these fixes? [Yes/No]"
If yes, apply all fixes using Edit tool.
Output
- File-by-file review with scores
- Summary: total files, average score, critical issue count
- Actionable fix list
- Coverage gaps identified (pages/features with no tests)
अक्सर पूछे जाने वाले सवाल
यह किस तरह की समस्याएँ ढूँढती है?
उदाहरण के लिए तय इंतज़ार, जहाँ role-आधारित सेलेक्टर उपलब्ध हों वहाँ CSS सेलेक्टर, हार्डकोड URL और ऐसे टेस्ट जो एक-दूसरे पर निर्भर हों।
क्या सारे नतीजे तुरंत ठीक करने लायक हैं?
नहीं। स्किल मुद्दों को गंभीर अनिवार्य सुधार, जल्द ठीक करने वाली चेतावनियों और विचार के लिए सूचना में बाँटती है।
क्या यह एक ही फ़ाइल की समीक्षा कर सकती है?
हाँ। आप उसे एक फ़ाइल या एक फ़ोल्डर दे सकते हैं, या खाली छोड़कर पूरा टेस्ट फ़ोल्डर जँचवा सकते हैं।
जानकारी
लेखक का मूल विवरण
Use when reviewing Playwright tests for quality ('review tests', 'audit tests', 'playwright best practices check').
लोकप्रियता
- GitHub स्टार
- 29k
- रैंकिंग में स्थान
- #9478
- लाइसेंस
- MIT
- अपडेट की गई
- 2/11/2026
कमेंट
- …
इस repository की और skills
agent-launcher-orchestrator
29kआपके एजेंट को एक साफ़ लक्ष्य से शुरू करके, अपने खाते में Claude मैनेज्ड एजेंट की योजना बनाने, बनाने, जांचने और शेड्यूल करने में चरण-दर-चरण मदद करती है।
grade-iterate
29kआपके एजेंट को किसी मैनेज्ड AI एजेंट के काम को रूब्रिक से आंकने और तय संख्या के दौरों में सुधारने देती है, ताकि वह कभी अनंत चक्र में न फंसे।
interview
29kआपके एजेंट को AI एजेंट के विचार पर आपसे इंटरव्यू लेने और कुछ भी लॉन्च होने से पहले आपके जवाबों को सरल निर्माण योजना में बदलने देती है।
run-without-you
29kआपके एजेंट को मैनेज्ड AI एजेंट शेड्यूल पर या किसी घटना पर चलाने में मदद करती है, लॉन्च से पहले cron समय की जांच के साथ।
मिलती-जुलती skills
test-driven-development
311kयह आपके एजेंट को किसी भी फ़ीचर या सुधार से पहले पहले असफल होने वाला टेस्ट लिखना, उसे असफल होते देखना, फिर पास करने वाला सबसे छोटा कोड लिखना सिखाती है।
verification-before-completion
311kयह आपके एजेंट को किसी काम, सुधार या build के पूरा या पास होने का दावा करने से पहले असली जांच चलाकर उसका आउटपुट पढ़ना सिखाती है।
migrate-to-shoehorn
310kआपकी टेस्ट फ़ाइलों में जोखिम भरे type casts की जगह shoehorn लाइब्रेरी लगाती है, ताकि टेस्ट अधूरे डेटा से भी type checks पास कर सकें।