Skip to content

Commit b0d4750

Browse files
DavertMikclaude
andcommitted
docs(agents): add Essential Setup section for skills + MCP
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
1 parent 493f5ef commit b0d4750

1 file changed

Lines changed: 32 additions & 25 deletions

File tree

docs/agents.md

Lines changed: 32 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,38 @@ Agents get full control over test and browser execution:
2323

2424
CodeceptJS is token-efficient: it stores HTML, ARIA, logs, and HTTP request data as files instead of streaming them through MCP. Agents read these files with their native shell tools—no extra API calls, no redundant context.
2525

26+
## Essential Setup
27+
28+
Two things make agent testing work: the **skills** that teach the agent CodeceptJS, and the **MCP server** that lets it drive the browser. Set both up once, from your project directory.
29+
30+
Install the skills:
31+
32+
```bash
33+
npx skills add codeceptjs/skills
34+
```
35+
36+
Connect the MCP server (`npx codeceptjs-mcp`).
37+
38+
**Claude Code:**
39+
40+
```bash
41+
claude mcp add codeceptjs -- npx codeceptjs-mcp
42+
```
43+
44+
**Codex:**
45+
46+
```bash
47+
codex mcp add codeceptjs -- npx codeceptjs-mcp
48+
```
49+
50+
**Cursor** — add to `.cursor/mcp.json`:
51+
52+
```json
53+
{ "mcpServers": { "codeceptjs": { "command": "npx", "args": ["codeceptjs-mcp"] } } }
54+
```
55+
56+
See [/mcp](/mcp) for full client setup. Now the agent is ready to run the loop.
57+
2658
## The loop
2759

2860
Whether the agent is writing a new test or fixing an old one, it follows the same cycle.
@@ -96,31 +128,6 @@ Only `url` is inline. The rest are paths the agent opens with the right tool:
96128

97129
Saved HTML is formatted, with non-semantic elements stripped out: `<style>`, `<script>`, Tailwind-style trash classes, and inline `style=""` attributes. `grep` can then effectively find the correct tree branch in raw page source. ARIA snapshots are smaller and more structured than HTML, which is why the agent prefers them when picking locators.
98130

99-
## Setup
100-
101-
When CodeceptJS is installed, the MCP server can be launched with this command:
102-
103-
```bash
104-
npx codeceptjs-mcp
105-
```
106-
107-
> See [/mcp](/mcp) for detailed client setup.
108-
109-
We recommend pairing CodeceptJS MCP with the skills bundle.
110-
111-
Install for any agent:
112-
113-
```bash
114-
npx skills add codeceptjs/skills
115-
```
116-
117-
Or, in Claude Code:
118-
119-
```text
120-
/plugin marketplace add codeceptjs/skills
121-
/plugin install codeceptjs@codeceptjs-skills
122-
```
123-
124131
## Usage Examples
125132

126133
When MCP and skills are connected, the agent receives predefined workflows and can act effectively for testing purposes. Common scenarios it handles:

0 commit comments

Comments
 (0)