원클릭으로
define-examples
Use when creating or updating example files that compose named test-data from constraints
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
메뉴
Use when creating or updating example files that compose named test-data from constraints
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
SOC 직업 분류 기준
Use when logging a bug, classifying severity, referencing a bug in a spec, or reconciling a deviation between expected and actual behaviour — governs the bug entry schema, ID format, status lifecycle, AI-automated vs manual channels, and `req.bugs` spec integration.
Use when testing colour-themed UI elements or maintaining colour keys — asserting CSS colours through the typed `colours` map and keeping the flat dot-namespaced key convention consistent across theme files, generated types, specs, and commands. Triggers on new colour assertions, hardcoded RGB/hex values in specs, missing-key type errors, duplicate values, theme-switch assertions, or colour value changes.
Use when designing or reviewing specifications to follow constraints-examples-specs traceability model
Use when creating or updating compact, tag-based skill files in `.claude/skills/`.
Use when defining or changing any reusable test boundary — min/max lengths, ranges, formats, regex, enums, allowed/required fields, status codes, durations, timeouts, display options, or valid/invalid value sets. Triggers on new constraint files, editing any `*.constraints.js` file under `cypress/constants/`, a hardcoded boundary/enum/format literal appearing in a spec or example, "add a validation rule", "what are the valid values", boundary or edge-case values, or duplicated limits that need one owner.
Use when adding or updating a custom ESLint rule, hitting a `custom/*` lint error, suppressing a rule inline, or understanding what a project custom rule enforces and why.
| name | define-examples |
| description | Use when creating or updating example files that compose named test-data from constraints |
SINGLE_OWNER: examples own instance composition, specs reference without reconstruction — otherwise setup and assertion data drift apart across the specs that rebuild it SEGMENTATION: one example file per spec mirror — otherwise a shared file couples unrelated specs and hides which data a spec depends on DERIVATION: compute values from structure and read dependencies at access time, never restate them — otherwise hardcoded copies silently rot when the source changes TRACEABILITY: boundary values flow from constraints into examples into specs — otherwise a value invented in the example breaks the constraint-to-spec chain VISIBILITY: examples fully show how each case is built — otherwise builders, defaults, and broad spreads hide the data that explains the requirement RUNTIME_ONLY_GETTERS: getters exist only for values unavailable until setup response time — otherwise static example data becomes unnecessarily lazy and hard to inspect
SCOPE: cypress/integration-examples/{api,ui}/, cypress/e2e-examples/ui/
API: cypress/integration-examples/api/module-name.submodule-name.api.examples.js
UI: cypress/integration-examples/ui/page-name.component-name.ui.examples.js
E2E: cypress/e2e-examples/ui/workflow-name.ui.examples.js
FILE_NAMES: kebab-case, spec mirror
EXPORT_NAME: _examples suffix
INSTANCE_KEY: {purpose}{QualifierSuffix?} — single lowerCamelCase token (^[a-z][a-zA-Z0-9]*$)
CONTAINER_KEY: entity + instance type, validity, role, or lifecycle (validQuestions, invalidQuestions, sourceQuestions, dependentAnswers)
NAME_STYLE: semantic intent (withAllFields, firstnameAtMaxLength, missingFirstname) — a reader infers the test aspect from the key alone
FIELD_MIRROR: property keys mirror exact API/UI field names — no renaming step between example and spec
NO_SUFFIX_PARALLELS: nested keyed instances over flat parallel keys (questions: { hygiene, structure } not hygieneId, structureId) — nesting keeps related instances co-located
NO_GENERIC: never item1, data1, test1, standard, default — generic keys carry no test intent
FULLY_CONSTRUCTED_INSTANCES: each named instance is fully composed in the example file with its static, constrained, randomized, setup, and assertion fields visible inline — otherwise the reader cannot see how that case's data is built
GROUP_BY_INSTANCE_TYPE: group sibling examples by entity plus instance type, validity, role, or lifecycle before the named case — otherwise unrelated valid, invalid, source, and dependent data become mixed
DYNAMIC_ID_GETTERS_ONLY: getters are allowed only for runtime-populated identifiers or server-generated values unavailable until setup response time, such as id, questionId, auditId, or userId
DYNAMIC_SOURCE_PLACEHOLDER: the source instance owns the mutable placeholder field (id: undefined or equivalent); dependent instances read it with a getter and are never reassigned by the spec
NO_STATIC_GETTERS: static values, constraint-derived values, randomized values, labels, request bodies, expected values, and known cross-field copies are plain fields — otherwise examples become lazy without runtime need
DERIVE_AGGREGATES: compute aggregates from structure (Object.keys(...).length), never hardcode — the count stays correct as fields change
COMPOSED_NESTING: each nested instance holds every field including dynamic placeholders
NO_HIDDEN_COMPOSITION: do not hide case data behind factories, builders, base, default, or broad object spreads — otherwise the important field differences are invisible at the named instance
SHARED_CONSTS_ONLY: extract a const only when the exact value is genuinely shared by multiple siblings and does not hide case-specific fields
BOUNDARIES: imported constraints for boundary values
RANDOM_SOURCE: utils for generated names, dates, numbers
CLEANUP_PREFIX: spec-specific root namePrefix
INSTANCE_COMPLETENESS: every instance holds all fields needed for setup and assertion
EXPLICIT_CASE_DATA: each case shows its concrete request, setup, and assertion values directly in the named instance — otherwise the spec cannot be audited from examples alone
SPEC_CALLS: pass examples.instanceType.instanceName directly without rebuilding
SPEC_DYNAMIC_ASSIGNMENT: specs assign runtime IDs only to source placeholders; specs never rebuild dependent instances or manually copy IDs into them
NAMING_CHECK: keys match ^[a-z][a-zA-Z0-9]*$, export uses _examples suffix
GROUPING_CHECK: instances are grouped by entity plus type, validity, role, or lifecycle before individual case names
MIRROR_CHECK: property keys mirror API/UI field names
GETTER_CHECK: getters appear only for runtime dynamic identifiers or server-generated values; static, constrained, randomized, expected, and display values are plain fields
HIDDEN_COMPOSITION_CHECK: no factories, builders, generic defaults, broad base objects, or broad spreads hide case-specific data
DERIVE_CHECK: aggregates compute from structure
TRACE_CHECK: boundaries import from constraints, specs reference directly
COMPLETENESS_CHECK: every instance includes all fields for its spec context
CLEANUP_CHECK: root namePrefix present and used by spec cleanup