Umbraco Msw Testing

🌐Community
by umbraco · vlatest · Repository

Automates Umbraco website testing using Microsoft Playwright, ensuring content and functionality meet quality standards.

Install on your platform

We auto-selected Claude Code based on this skill’s supported platforms.

1

Run in terminal (recommended)

terminal
claude mcp add umbraco-msw-testing npx -- -y @trustedskills/umbraco-msw-testing
2

Or manually add to ~/.claude/settings.json

~/.claude/settings.json
{
  "mcpServers": {
    "umbraco-msw-testing": {
      "command": "npx",
      "args": [
        "-y",
        "@trustedskills/umbraco-msw-testing"
      ]
    }
  }
}

Requires Claude Code (claude CLI). Run claude --version to verify your install.

About This Skill

What it does

This skill enables AI agents to perform isolated unit and integration testing for Umbraco backoffice applications using Mock Service Worker (MSW). It allows developers to intercept and mock HTTP requests, ensuring tests run without relying on external network dependencies or a running backend.

When to use it

  • Isolate Logic: Verify specific components in the Umbraco backoffice by mocking API responses to prevent flaky tests caused by network latency.
  • Offline Development: Run comprehensive test suites locally without needing to spin up a full Umbraco instance or database connection.
  • Simulate Edge Cases: Artificially trigger error states (e.g., 500 errors, timeouts) to ensure the UI handles failures gracefully.
  • Speed Up CI/CD: Reduce build times by replacing slow live server calls with instant mock data in automated pipelines.

Key capabilities

  • Intercepts outgoing HTTP requests within the Umbraco backoffice environment.
  • Allows configuration of custom mock responses for specific endpoints.
  • Facilitates deterministic testing outcomes independent of external services.
  • Integrates directly with standard JavaScript testing frameworks.

Example prompts

  • "Set up a test suite that mocks the /api/media endpoint to return a specific image list when running Umbraco backoffice unit tests."
  • "Configure MSW to simulate a 401 Unauthorized response for the login API to verify the error handling UI in my Umbraco component."
  • "Write an integration test where I mock the CMS content delivery to ensure the dashboard renders correctly without hitting the live database."

Tips & gotchas

Ensure your test environment has MSW properly installed and configured before attempting to run tests, as the skill relies on this library for request interception. Be mindful that mocking only covers client-side logic; server-side validation or database constraints will still require a real backend or additional mock strategies.

Tags

🛡️

TrustedSkills Verification

Unlike other registries that point to live repositories, TrustedSkills pins every skill to a verified commit hash. This protects you from malicious updates — what you install today is exactly what was reviewed and verified.

Security Audits

Gen Agent Trust HubPass
SocketPass
SnykPass

Details

Version
vlatest
License
Author
umbraco
Installs
37

🌐 Community

Passed automated security scans.