Cypress
Write reliable E2E and component tests with Cypress avoiding flaky selectors, race conditions, and CI failures.
Why use this skill?
Master Cypress testing with OpenClaw. Learn to write flaky-free E2E and component tests, implement robust selectors, and automate CI/CD workflows efficiently.
Install via CLI (Recommended)
clawhub install openclaw/skills/skills/ivangdavila/cypressWhat This Skill Does
The Cypress skill empowers your OpenClaw agent to become an expert Quality Assurance engineer. It provides the agent with deep knowledge of the Cypress testing framework, enabling it to write resilient end-to-end (E2E), component, and API tests. The skill focuses on modern testing best practices, such as using data-testid attributes for stable selectors, implementing intercept-based network management, and leveraging custom commands to DRY up your test suite. It is designed to minimize flakiness, improve CI/CD pipeline reliability, and ensure that your web applications remain robust throughout development lifecycles.
Installation
To install this skill, run the following command in your terminal:
clawhub install openclaw/skills/skills/ivangdavila/cypress
Ensure your project is already initialized with Cypress (npm install cypress --save-dev). Once installed, review the setup.md file in your repository to configure your specific test environment.
Use Cases
- Automated Regression Testing: Ensuring critical user flows like login, checkout, and signup continue to work after new code deployments.
- Component Isolation: Testing individual UI components in isolation to identify logic errors without full application load.
- API Contract Testing: Validating backend API responses using
cy.interceptto mock data and test frontend handling of various HTTP statuses. - Debugging Flaky Specs: Using the agent to refactor existing tests that suffer from race conditions or brittle CSS selectors.
- CI/CD Integration: Configuring headless execution for GitHub Actions or other CI pipelines to prevent merging broken code.
Example Prompts
- "Create a new Cypress E2E test for the user login flow that uses a custom
cy.logincommand and validates the dashboard redirect." - "Review my current test suite and refactor the selectors to use
data-testidinstead of fragile CSS classes like.container > div > span." - "My tests are failing intermittently on CI because the API call takes too long. Can you update the test to intercept the API request and wait for it properly?"
Tips & Limitations
- Prioritize Data Attributes: Always encourage developers to add
data-testidto elements that need testing. This is the single most effective way to eliminate selector-related flakiness. - Avoid Fixed Waits: Never use
cy.wait(ms). Always hook into application state or network interception to trigger the next step in the test. - State Management: Use
cy.sessionto cache authentication states, which significantly speeds up test execution. - Limitations: This skill relies on the existing project structure. If your project does not follow standard Cypress conventions, the agent may need initial guidance to map your specific folder structure.
Metadata
Not sure this is the right skill?
Describe what you want to build — we'll match you to the best skill from 16,000+ options.
Find the right skillPaste this into your clawhub.json to enable this plugin.
{
"plugins": {
"official-ivangdavila-cypress": {
"enabled": true,
"auto_update": true
}
}
}Tags(AI)
Flags: file-write, file-read, code-execution
Related Skills
Animations
Create performant web animations with proper accessibility and timing.
Arduino
Develop Arduino projects avoiding common wiring, power, and code pitfalls.
Bulgarian
Write Bulgarian that sounds human. Not formal, not robotic, not AI-generated.
Arabic
Write Arabic that sounds human. Not formal, not robotic, not AI-generated.
Assistant
Manage tasks, communications, and scheduling with proactive and organized support.