Skills

Add Feature Test

Given a plain-language description of an EXISTING Chamilo feature (a tool, a form, an...

Install

npx skills add chamilo/chamilo-lms --skill add-feature-test -g -a claude-code -y
Category
Design
Updated
3d ago
License
GPL-3.0
Context cost
Mediumabout 3,000 tokens
Runs scripts
No, instructions only

What it does

Given a plain-language description of an EXISTING Chamilo feature (a tool, a form, an admin page, anything reachable in the running app), locate its current implementation (legacy PHP or Vue SPA), explore the live rendered UI to confirm real selectors/behavior, and author a complete, non-duplicating Playwright/Gherkin test suite for it in tests/playwright/features/. Use when the user describes a feature and asks for test coverage, wants to "add tests for X", asks to confirm a feature "keeps working", or runs /add-feature-test. Companion to the Playwright section of CLAUDE.md.

Add Feature Test

Turn a plain-language feature description into a Playwright/Gherkin test suite that actually reflects the live application, not assumptions from reading source code alone. Static code reading gets selectors, field names, dialog types, and even which page is actually live wrong often enough that every one of those claims must be confirmed against a running instance before it goes into a test.

Scope, per the user's own framing: wide-ranging, not exhaustive. Cover the feature's real create/read/update/delete flows and role-based access variants that a normal user would actually hit. Do not chase combinatorial platform- setting states or contrived edge cases nobody would realistically trigger.


Step 0, Get the feature description straight

If the description could point at more than one page (a feature that exists both as a legacy tool and a parallel/newer Vue equivalent, or a name that's ambiguous inside Chamilo's domain), ask which one before doing any real work. Otherwise proceed, most descriptions ("the Agenda tool", "creating a session", "the document manager") are unambiguous enough to just go find.

Step 1, Locate the current implementation

Search BOTH possible homes, this codebase is mid-migration and a feature can live in either, or have moved without every caller being updated:

  • Legacy PHP: public/main/<domain>/*.php, public/main/inc/lib/*.lib.php for the form-building logic.
  • Vue SPA: assets/vue/views/<domain>/*.vue, assets/vue/router/<domain>.js.
Read the whole SKILL.md on GitHub

More in Design