Skip to content
Skillv1.0.0

cypress-expert

Expert in Cypress testing framework, custom commands, fixtures, plugins, visual testing, and component testing. Use when the user mentions testing, end-to-end tests, QA, automation, end-to-end testing

by personamanagmentlayer(0) 0 installs
Free
Sign in to install

Free account. Installing gives you the manifest plus copy-paste snippets.

See reviews

About

Imported from personamanagmentlayer/pcl (stdlib/qa/cypress-expert/SKILL.md). Install upstream with npx skills add personamanagmentlayer/pcl --skill cypress-expert. Copyright stays with the author.

Cypress Expert

Core Concepts

Cypress Framework

  • JavaScript-Based - Native JavaScript testing
  • Real-Time Reloads - Auto-reloading on file changes
  • Time Travel - Debug via snapshots
  • Automatic Waiting - No explicit waits needed
  • Network Control - Request stubbing and spying
  • Screenshots & Videos - Built-in capture

Test Structure

  • describe/it - Mocha-style test organization
  • Hooks - before, beforeEach, after, afterEach
  • Custom Commands - Reusable test logic
  • Fixtures - Test data management
  • Aliases - Reference DOM elements and requests
  • Chains - Fluent command interface

Advanced Features

  • Intercepts - Network request control
  • Component Testing - React, Vue, Angular components
  • Visual Testing - Applitools integration
  • Code Coverage - Test coverage reports
  • Parallelization - Cypress Cloud parallel execution
  • Plugins - Extend functionality

Best Practices

Test Organization

  • Keep tests independent and isolated
  • Use descriptive test names
  • Group related tests with describe blocks
  • Use beforeEach for common setup
  • Clean up after tests
  • Avoid test interdependencies

Selectors

  • Prefer data-* attributes for testing
  • Use cy.contains() for text-based selection
  • Avoid CSS classes and IDs tied to styling
  • Use role-based selectors when possible
  • Create stable selectors
  • Document selector strategies

Assertions

  • Use should() for auto-retry assertions
  • Chain assertions when appropriate
  • Test both positive and negative cases
  • Provide meaningful assertion messages
  • Use explicit assertions
  • Verify multiple aspects

Performance

  • Use cy.session() for authentication
  • Leverage fixtures for test data
  • Mock external API calls
  • Minimize page visits
  • Use aliases to avoid repeated queries
  • Run tests in parallel with Cypress Cloud

Anti-Patterns

Common Mistakes

  • Using cy.wait() with arbitrary time
  • Not using data-testid attributes
  • Overly complex test logic
  • Sharing state between tests
  • Testing implementation details
  • Missing cleanup in afterEach

Selector Issues

  • Using fragile CSS selectors
  • Relying on element position
  • Not using data attributes
  • Over-specific selectors
  • Using XPath unnecessarily
  • Coupling tests to UI structure

Test Design Problems

  • Tests depending on execution order
  • Too many assertions in one test
  • Not testing edge cases
  • Missing error scenarios
  • Duplicate test logic
  • Poor fixture management

Reference Documentation

Detailed material lives alongside this skill and is read on demand:

  • Implementation Examples — Basic Test Structure, Custom Commands, Network Interception, Fixtures and Test Data, Page Object Pattern, Component Testing, Configuration (cypress.config.js)

Resources

Official Documentation

Learning Resources

Tools & Extensions

Community Resources

Use it

Copy one of these into your project. Installing also returns the manifest and these snippets.

yaml
targets:
  - https://api.opensmartroute.ai/api/v1/registry/personamanagmentlayer-pcl-cypress-expert/manifest   # or paste the manifest below

Manifest

An Open Capability Manifest: the router reads it to know what this does, what it costs and when to pick it.

personamanagmentlayer-pcl-cypress-expert.ocm.jsonjson
{
  "ocm": "1",
  "id": "personamanagmentlayer-pcl-cypress-expert",
  "kind": "skill",
  "name": "cypress-expert",
  "description": "Expert in Cypress testing framework, custom commands, fixtures, plugins, visual testing, and component testing. Use when the user mentions testing, end-to-end tests, QA, automation, end-to-end testing, or Cypress commands, or when the task involves Cypress Framework, Test Structure, Advanced Features, or Custom Commands.",
  "publisher": "personamanagmentlayer",
  "version": "1.0.0",
  "capabilities": {
    "domains": [
      "coding"
    ],
    "tags": [
      "skill-md",
      "testing",
      "e2e",
      "cypress",
      "qa",
      "automation",
      "e2e-testing",
      "cypress-commands",
      "fixtures",
      "cypress-plugins"
    ],
    "languages": [
      "en"
    ]
  },
  "quality_prior": 0.6,
  "examples": [
    "Expert in Cypress testing framework, custom commands, fixtures, plugins, visual testing, and component testing. Use when the user mentions testing, end-to-end tests, QA, automation, end-to-end testing, or Cypress commands, or when the task involves Cypress Framework, Test Structure, Advanced Features, or Custom Commands."
  ],
  "primary": false,
  "metadata": {
    "source": {
      "provider": "skills.sh",
      "repository": "https://github.com/personamanagmentlayer/pcl",
      "path": "stdlib/qa/cypress-expert/SKILL.md",
      "ref": "HEAD",
      "url": "https://github.com/personamanagmentlayer/pcl/blob/HEAD/stdlib/qa/cypress-expert/SKILL.md",
      "key": "personamanagmentlayer/pcl/stdlib/qa/cypress-expert/SKILL.md"
    },
    "allowed_tools": [
      "Read",
      "Write",
      "Edit",
      "Bash",
      "Grep",
      "Glob"
    ]
  },
  "instructions": "# Cypress Expert\n\n## Core Concepts\n\n### Cypress Framework\n\n- **JavaScript-Based** - Native JavaScript testing\n- **Real-Time Reloads** - Auto-reloading on file changes\n- **Time Travel** - Debug via snapshots\n- **Automatic Waiting** - No explicit waits needed\n- **Network Control** - Request stubbing and spying\n- **Screenshots & Videos** - Built-in capture\n\n### Test Structure\n\n- **describe/it** - Mocha-style test organization\n- **Hooks** - before, beforeEach, after, afterEach\n- **Custom Commands** - Reusable test logic\n- **Fixtures** - Test data management\n- **Aliases** - Reference DOM elements a",
  "cost": {
    "context_tokens": 1062
  }
}

Fetch it by URL: GET /api/v1/registry/personamanagmentlayer-pcl-cypress-expert/manifest?version=1.0.0

Reviews

Star ratings from people who tried it. One review per account; edit yours any time.

No reviews yet. Install it, try it, and be the first to rate it.