agentforce-architectur…
Declared architecture snapshot for one Agentforce agent: planner, topics, actions, flows, Apex, prompt templates, and NGA…
Use ALWAYS when running Sa11y accessibility Jest tests for an LWC — locally before pushing, producing the command(s), running one file vs a suite, selecting tests by naming convention, saving Sa11y-rendered HTML, or reproducing a Sa11y/A11yBug failure. Covers core (Bazel; `bazel
Claude Code
$ npx -y skills add forcedotcom/sf-skills --skill experience-lwc-accessibility-jest-run --agent claude-code
Codex
$ npx skills add forcedotcom/sf-skills --skill experience-lwc-accessibility-jest-run -a codex -y
Cursor
$ npx skills add forcedotcom/sf-skills --skill experience-lwc-accessibility-jest-run -a cursor -y
Gemini CLI
$ npx skills add forcedotcom/sf-skills --skill experience-lwc-accessibility-jest-run -a gemini-cli -y
GitHub Copilot
$ npx skills add forcedotcom/sf-skills --skill experience-lwc-accessibility-jest-run -a github-copilot -y
OpenCode
$ npx skills add forcedotcom/sf-skills --skill experience-lwc-accessibility-jest-run -a opencode -y
Windsurf
$ npx skills add forcedotcom/sf-skills --skill experience-lwc-accessibility-jest-run -a windsurf -y
name: experience-lwc-accessibility-jest-run
description: "Use ALWAYS when running Sa11y accessibility Jest tests for an LWC — locally before pushing, producing the command(s), running one file vs a suite, selecting tests by naming convention, saving Sa11y-rendered HTML, or reproducing a Sa11y/A11yBug failure. Covers core (Bazel; `bazel test //<module>:<target>`) and standalone `npx jest` (`.accessibility.test.js`, `@sa11y/jest`). REQUIRED for a `run-plan.md`, a failing a11y test's exit code, or `SA11Y_*`/`A11yBug`/core-Bazel test paths. DO NOT TRIGGER for functional Jest tests, a11y review without running tests (use experience-accessibility-validate), or Selenium-based a11y tests."
metadata:
version: "1.0"
domains: ["Experience"]
relatedSkills:
- "experience-accessibility-validate"
cliTools:
- tool: ["node"]
semver: ">=18.0.0"
- tool: ["npm"]
semver: ">=8.0"<!-- a11y-expert-managed-skill -->
Run Sa11y accessibility unit tests on Lightning Web Components in either:
Selenium-level reproductions, GUS A11yBug ingestion, and other internal Salesforce-only flows are out of scope for this skill. For source-code-level WCAG review without running tests, see `experience-accessibility-validate`.
pushing a fix.
`Test_Names__c`) and wants to target it directly.
pass/fail signal.
file is present).
Choose the approach based on the environment. If this is not a Salesforce core build environment, do not mention the Core workflow.
Use this mode when a `WORKSPACE` file is present. The base command is:
{coreRootPath}/tools/bazel test [TARGET] --test_output=streamed --test_env=SA11Y_AUTO=1 --test_env=SA11Y_ENABLE_DOM_MUTATION_OBSERVER=1Replace `{coreRootPath}` with the Core repository root, `{moduleName}` with the module name, and `{relativePath}` with the test file path without the `.test.js` extension.
To discover targets and paths:
find {coreRootPath}/{moduleName} -name "*.test.js" -type f
{coreRootPath}/tools/bazel query "tests(//{moduleName}:*)"Component tests typically live under `modules/{componentDir}/{componentName}/__tests__/`.
Prefer a single-file target when the failing test path is known:
{coreRootPath}/tools/bazel test //{moduleName}:{relativePath} --test_output=streamed --test_env=SA11Y_AUTO=1 --test_env=SA11Y_ENABLE_DOM_MUTATION_OBSERVER=1Run all Sa11y Jest tests in a module when a specific test is not known:
{coreRootPath}/tools/bazel test //{moduleName}:sa11y_jest_test --test_output=streamed --test_env=SA11Y_AUTO=1 --test_env=SA11Y_ENABLE_DOM_MUTATION_OBSERVER=1Multiple module targets can be passed to the same command. To filter tests within a module, add `--test_arg=--testMatch="**/{modulePath}/**"`.
Useful options:
`--test_env=SA11Y_ENABLE_RENDERED_DOM_SAVE=1 --test_env=SA11Y_RENDERED_DOM_SAVE_PATH=sfdc-test/unit/javascript/htdocs/sa11y/jest`
Use `sfdc-test/unit/javascript/htdocs/sa11y/jest` as the rendered DOM save path to avoid EPERM errors.
Use this mode when no `WORKSPACE` file is present. Run all accessibility tests:
Do **not** prepend `SA11Y_*` environment variables in standalone mode; `@sa11y/jest` is activated through the project's Jest setup.
npm test -- --testMatch="**/*.accessibility.test.js"
Or target a specific file:
npm test -- src/components/MyComponent/__tests__/MyComponent.accessibility.test.js
Use the filename or path supplied by the user. When the named test is in the current directory, keep a bare filename bare instead of inventing a path.
Other useful options are `--coverage`, `--updateSnapshot`, `--watch`, and `--verbose`. To target a named test, use `npm test -- --testNamePattern="MyComponent accessibility"`.
Ensure Jest uses a `jsdom` environment and loads the project's `@sa11y/jest` setup file. Copy or adapt the bundled `assets/jest.config.js` template into the project's Jest configuration, and copy `assets/sa11y-jest-setup.js` to `test/setup/sa11y-setup.js`. If the project already has a Jest configuration, merge the relevant settings instead of overwriting unrelated configuration.
The `SA11Y_*` variables shown above are for Core/Bazel only; the Bazel commands already include them.
Answer only what the user asked. Emit the requested command or commands plus the relevant exit-code meaning. Do not add watch, coverage, snapshot-update, HTML-save, or other variants unless the user requests them.
build or command failed.
occurred.
for Bazel; exit 0 or 1 for Jest).
committed alongside the fix.
`.test.js` extension in `{relativePath}`.
`sfdc-test/unit/javascript/htdocs/sa11y/jest`.
c
This repository provides Salesforce agent skills, plugins, and sample apps for building applications.
Declared architecture snapshot for one Agentforce agent: planner, topics, actions, flows, Apex, prompt templates, and NGA…
Use this skill to Upgrade Einstein Bots into Agentforce agents end-to-end in a single pass, orchestrating per-bot Agent Spec…
Data Cloud 360° view of a single Agentforce session. TRIGGER when user asks to trace, inspect, summarize, or describe a specific…
Build, modify, audit, repair, optimize, debug, and deploy agents with Agentforce Agent Script. TRIGGER when: user creates,…
Analyze production Agentforce agent behavior using session traces and Data Cloud, and manage Agent Health Monitoring (AHM)…
Use to design an AI agent persona — identity, voice, tone, behavioral style, guardrails — and encode it into Agent Script (.agent…
You MUST use this before any creative work - creating features, building components, adding functionality, modifying behavior, or…
Ask which skill or flow fits your situation. A router over the skills in this repo.