jquery-testing-skill

Standardize jQuery DOM and unit tests with Jest, Vitest, and Jasmine.

Updated Aug 23, 2026
One-click install
npx skills add https://github.com/ialae/peliku --skill jquery-testing-skill
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: jquery-testing-skill
Source: https://github.com/ialae/peliku/tree/main/.github/skills/jquery-testing-skill
Command: npx skills add https://github.com/ialae/peliku --skill jquery-testing-skill

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This skill provides best practices for testing jQuery code with Jest, Vitest, and Jasmine, covering unit tests, DOM tests, event testing, AJAX mocking, plugin testing, and anti-patterns. It helps ensure reliable, maintainable test suites.

Core Features & Use Cases

  • Setup and configuration for Vitest/Jest with jsdom
  • DOM manipulation testing patterns
  • Event handling and AJAX mocking
  • Plugin testing and test utilities
  • Use cases: ensuring robust jQuery tests during refactors

Quick Start

Install dependencies, configure your test runner, and write a basic DOM test to verify jQuery interactions.

Frequently Asked Questions about jquery-testing-skill

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I test jQuery DOM manipulation with Vitest or Jest?

Test jQuery DOM manipulation by configuring Vitest or Jest with jsdom to simulate browser environments. This allows you to verify UI component interactions and DOM updates reliably without a real browser, ensuring robust refactoring.

What is the best way to mock AJAX requests in jQuery unit tests?

The best way to mock AJAX requests in jQuery tests is by using built-in event and AJAX mocking patterns provided by Jest, Vitest, or Jasmine. This isolates network dependencies and ensures your plugin behavior and event handling tests remain deterministic.

Can I use Jasmine to test jQuery plugin behavior and events?

Yes, you can use Jasmine to test jQuery plugin behavior and events. The skill provides standardized testing patterns for plugin testing, event handling, and DOM interactions, ensuring reliable and maintainable test suites across Jasmine, Jest, and Vitest.

Why does my jQuery test fail to find DOM elements in jsdom?

jQuery tests fail to find DOM elements in jsdom when test setup configuration is incorrect or missing. Properly initializing the jsdom environment and following standardized DOM test patterns ensures elements are present and queryable before assertions run.

What anti-patterns should I avoid when testing jQuery code?

Avoid jQuery testing anti-patterns by following standardized unit and DOM test practices. The skill enforces proper test setup configuration, event and AJAX mocking, and plugin testing patterns to prevent flaky tests and ensure maintainable UI component behavior.