e2e-testing
它能做什么
这是一份指南,介绍如何自动测试用户与网站或应用的交互过程。它能帮助你确保各种浏览器和场景下,一切都按预期工作。
适用场景
- ✓为网站设置自动化测试时。
- ✓需要检查网站在多种浏览器上能否正常工作时。
- ✓想将网站外观与之前的版本进行对比(视觉测试)时。
技能链接
https://github.com/sickn33/agentic-awesome-skills/blob/main/plugins/agentic-awesome-skills-claude/skills/e2e-testing/SKILL.md复制后粘贴给你的 AI(Claude、ChatGPT 或 Cursor),让它按照说明操作。
使用方法
最简单的方法:复制下面的消息,粘贴给你的 AI。它会读取这个技能并按说明操作。
可直接粘贴的消息
适用于 Claude Code、Codex 或 Cursor:在项目文件夹中运行,即可安装该技能。
下载 SKILL.md,放进智能体的技能文件夹。
可以这样问 AI
“帮我设置自动化测试,检查我网站上的登录和购买流程。”
每周 5 个新技能,1 分钟读完。
工作原理
它使用一个叫 Playwright 的工具来模拟用户操作,比如点击按钮和填写表单。这样测试就可以在无需人工干预的情况下运行。
技术内容(原始 SKILL.md)
作者在 GitHub 上的英文原文。
E2E Testing Workflow
Overview
Specialized workflow for end-to-end testing using Playwright including browser automation, visual regression testing, cross-browser testing, and CI/CD integration.
When to Use This Workflow
Use this workflow when:
- Setting up E2E testing
- Automating browser tests
- Implementing visual regression
- Testing across browsers
- Integrating tests with CI/CD
Scope and proof
Choose phases needed for the current task, not every listed skill. Use dedicated test accounts, isolated fixtures and approved sandbox endpoints; clicks can send messages, make purchases or delete data. Review browser installation/downloads and CI permissions first. Traces, screenshots, videos and storage-state files can contain credentials or private data; keep them private and redact artifacts before sharing. A Playwright WebKit run is not proof on actual Safari/iOS, and mobile emulation is not a real-device test. Keep visual baselines fixed until differences are reviewed; do not overwrite them merely to get a pass.
Workflow Phases
Phase 1: Test Setup
Skills to Invoke
playwright-skill- Playwright setupe2e-testing-patterns- E2E patterns
Actions
- Install Playwright
- Configure test framework
- Set up test directory
- Configure browsers
- Create base test setup
Copy-Paste Prompts
Use @playwright-skill to set up Playwright testing
Phase 2: Test Design
Skills to Invoke
e2e-testing-patterns- Test patternstest-automator- Test automation
Actions
- Identify critical flows
- Design test scenarios
- Plan test data
- Create page objects
- Set up fixtures
Copy-Paste Prompts
Use @e2e-testing-patterns to design E2E test strategy
Phase 3: Test Implementation
Skills to Invoke
playwright-skill- Playwright testswebapp-testing- Web app testing
Actions
- Write test scripts
- Add assertions
- Implement waits
- Handle dynamic content
- Add error handling
Copy-Paste Prompts
Use @playwright-skill to write E2E test scripts
Phase 4: Browser Automation
Skills to Invoke
browser-automation- Browser automationplaywright-skill- Playwright features
Actions
- Configure headless mode
- Set up screenshots
- Implement video recording
- Add trace collection
- Configure mobile emulation
Copy-Paste Prompts
Use @browser-automation to automate browser interactions
Phase 5: Visual Regression
Skills to Invoke
playwright-skill- Visual testingui-visual-validator- Visual validation
Actions
- Set up visual testing
- Create baseline images
- Add visual assertions
- Configure thresholds
- Review differences
Copy-Paste Prompts
Use @playwright-skill to implement visual regression testing
Phase 6: Cross-Browser Testing
Skills to Invoke
playwright-skill- Multi-browserwebapp-testing- Browser testing
Actions
- Configure Chromium
- Add Firefox tests
- Add WebKit tests
- Test mobile browsers
- Compare results
Copy-Paste Prompts
Use @playwright-skill to run cross-browser tests
Phase 7: CI/CD Integration
Skills to Invoke
github-actions-templates- GitHub Actionscicd-automation-workflow-automate- CI/CD
Actions
- Create CI workflow
- Configure parallel execution
- Set up artifacts
- Add reporting
- Configure notifications
Copy-Paste Prompts
Use @github-actions-templates to integrate E2E tests with CI
Quality Gates
- Tests passing
- Coverage adequate
- Visual tests stable
- Cross-browser verified
- CI integration working
Related Workflow Bundles
testing-qa- Testing workflowdevelopment- Developmentweb-performance-optimization- Performance
Limitations
- Use this skill only when the task clearly matches the scope described above.
- Do not treat the output as a substitute for environment-specific validation, testing, or expert review.
- Stop and ask for clarification if required inputs, permissions, safety boundaries, or success criteria are missing.
常见问题
什么是“视觉回归”?
这是一种确保网站视觉外观不会意外改变的技术。它会把网站应有的样子的截图与当前的截图进行比较。
什么是“CI/CD 集成”?
指的是把这些测试接入持续集成和持续交付系统中。这样每当代码有改动时,测试都会自动运行。
测试结果能100%相信吗?
这些测试很有帮助,但不能替代人工审查。测试中可能包含敏感信息,所以分享测试结果时要小心。
详情
作者的原始描述
End-to-end testing workflow with Playwright for browser automation, visual regression, cross-browser testing, and CI/CD integration.
热度
- GitHub 星标
- 48k
- 排名
- #4504
- 许可证
- MIT
- 更新时间
- 2026/10/15
评论
- …
同一仓库的更多技能
00-andruia-consultant
48k帮你的智能体启动或改进 AI 项目。它可以分析代码、推荐工具,并用西班牙语制定行动计划。
007
48k让你的智能体执行安全审计和威胁建模。它有助于保护项目免受攻击和漏洞的威胁。
10-andruia-skill-smith
48k帮你的智能体创建或改进 AI 工具。它可以定义工具的工作方式、编写文档,并验证其结构。
20-andruia-niche-intelligence
48k让你的智能体创建某个特定行业的摘要。它有助于借助可靠的信息来源,了解项目的背景、规则、使用模式和风险。