@vizzly-testing/cli 0.23.0 → 0.23.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +54 -586
- package/dist/api/client.js +3 -1
- package/dist/api/endpoints.js +6 -7
- package/dist/cli.js +15 -2
- package/dist/commands/finalize.js +12 -0
- package/dist/commands/preview.js +210 -28
- package/dist/commands/run.js +15 -0
- package/dist/commands/status.js +34 -8
- package/dist/commands/upload.js +13 -0
- package/dist/reporter/reporter-bundle.iife.js +19 -19
- package/dist/utils/ci-env.js +114 -16
- package/package.json +1 -2
- package/claude-plugin/.claude-plugin/README.md +0 -270
- package/claude-plugin/.claude-plugin/marketplace.json +0 -28
- package/claude-plugin/.claude-plugin/plugin.json +0 -14
- package/claude-plugin/.mcp.json +0 -12
- package/claude-plugin/CHANGELOG.md +0 -85
- package/claude-plugin/commands/setup.md +0 -137
- package/claude-plugin/commands/suggest-screenshots.md +0 -111
- package/claude-plugin/mcp/vizzly-docs-server/README.md +0 -95
- package/claude-plugin/mcp/vizzly-docs-server/docs-fetcher.js +0 -110
- package/claude-plugin/mcp/vizzly-docs-server/index.js +0 -283
- package/claude-plugin/mcp/vizzly-server/cloud-api-provider.js +0 -399
- package/claude-plugin/mcp/vizzly-server/index.js +0 -927
- package/claude-plugin/mcp/vizzly-server/local-tdd-provider.js +0 -455
- package/claude-plugin/mcp/vizzly-server/token-resolver.js +0 -185
- package/claude-plugin/skills/check-visual-tests/SKILL.md +0 -158
- package/claude-plugin/skills/debug-visual-regression/SKILL.md +0 -269
- package/docs/api-reference.md +0 -1003
- package/docs/authentication.md +0 -334
- package/docs/doctor-command.md +0 -44
- package/docs/getting-started.md +0 -131
- package/docs/internal/SDK-API.md +0 -1018
- package/docs/plugins.md +0 -557
- package/docs/tdd-mode.md +0 -594
- package/docs/test-integration.md +0 -523
- package/docs/tui-elements.md +0 -560
- package/docs/upload-command.md +0 -196
package/dist/utils/ci-env.js
CHANGED
|
@@ -4,6 +4,47 @@
|
|
|
4
4
|
* Generic functions to extract git and PR information from any CI provider
|
|
5
5
|
*/
|
|
6
6
|
|
|
7
|
+
import { readFileSync } from 'node:fs';
|
|
8
|
+
|
|
9
|
+
// Cache for GitHub Actions event payload to avoid re-reading the file
|
|
10
|
+
let _githubEventCache = null;
|
|
11
|
+
|
|
12
|
+
/**
|
|
13
|
+
* Read and parse the GitHub Actions event payload from GITHUB_EVENT_PATH.
|
|
14
|
+
*
|
|
15
|
+
* GitHub Actions sets GITHUB_EVENT_PATH to a file containing the full webhook
|
|
16
|
+
* payload that triggered the workflow. This is essential for pull_request and
|
|
17
|
+
* pull_request_target events because GITHUB_SHA points to a merge commit,
|
|
18
|
+
* not the actual head commit.
|
|
19
|
+
*
|
|
20
|
+
* @returns {Object} Parsed event payload or empty object on failure
|
|
21
|
+
*/
|
|
22
|
+
export function getGitHubEvent() {
|
|
23
|
+
if (_githubEventCache !== null) {
|
|
24
|
+
return _githubEventCache;
|
|
25
|
+
}
|
|
26
|
+
let eventPath = process.env.GITHUB_EVENT_PATH;
|
|
27
|
+
if (!eventPath) {
|
|
28
|
+
_githubEventCache = {};
|
|
29
|
+
return _githubEventCache;
|
|
30
|
+
}
|
|
31
|
+
try {
|
|
32
|
+
let content = readFileSync(eventPath, 'utf8');
|
|
33
|
+
_githubEventCache = JSON.parse(content);
|
|
34
|
+
} catch {
|
|
35
|
+
// File doesn't exist or invalid JSON - fail silently with empty object
|
|
36
|
+
_githubEventCache = {};
|
|
37
|
+
}
|
|
38
|
+
return _githubEventCache;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
/**
|
|
42
|
+
* Reset the GitHub event cache. Useful for testing.
|
|
43
|
+
*/
|
|
44
|
+
export function resetGitHubEventCache() {
|
|
45
|
+
_githubEventCache = null;
|
|
46
|
+
}
|
|
47
|
+
|
|
7
48
|
/**
|
|
8
49
|
* Get the branch name from CI environment variables
|
|
9
50
|
* @returns {string|null} Branch name or null if not available
|
|
@@ -45,15 +86,41 @@ export function getBranch() {
|
|
|
45
86
|
}
|
|
46
87
|
|
|
47
88
|
/**
|
|
48
|
-
* Get the commit SHA from CI environment variables
|
|
89
|
+
* Get the commit SHA from CI environment variables.
|
|
90
|
+
*
|
|
91
|
+
* IMPORTANT: For GitHub Actions pull_request events, GITHUB_SHA points to a
|
|
92
|
+
* temporary merge commit, NOT the actual head commit of the PR. This function
|
|
93
|
+
* reads the event payload from GITHUB_EVENT_PATH to extract the correct SHA.
|
|
94
|
+
*
|
|
95
|
+
* See: https://docs.github.com/en/actions/using-workflows/events-that-trigger-workflows#pull_request
|
|
96
|
+
* "GITHUB_SHA for this event is the last merge commit of the pull request merge branch.
|
|
97
|
+
* If you want to get the commit ID for the last commit to the head branch of the
|
|
98
|
+
* pull request, use github.event.pull_request.head.sha instead."
|
|
99
|
+
*
|
|
49
100
|
* @returns {string|null} Commit SHA or null if not available
|
|
50
101
|
*/
|
|
51
102
|
export function getCommit() {
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
103
|
+
// Vizzly override always takes priority
|
|
104
|
+
if (process.env.VIZZLY_COMMIT_SHA) {
|
|
105
|
+
return process.env.VIZZLY_COMMIT_SHA;
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
// GitHub Actions: extract the correct SHA based on event type
|
|
109
|
+
if (process.env.GITHUB_ACTIONS) {
|
|
110
|
+
let event = getGitHubEvent();
|
|
111
|
+
|
|
112
|
+
// For pull_request events, use the actual head commit SHA (not the merge commit)
|
|
113
|
+
// The event payload contains pull_request.head.sha which is what we want
|
|
114
|
+
if (event.pull_request?.head?.sha) {
|
|
115
|
+
return event.pull_request.head.sha;
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
// For push events or if event parsing failed, GITHUB_SHA is correct
|
|
119
|
+
return process.env.GITHUB_SHA || null;
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
// Other CI providers
|
|
123
|
+
return process.env.CI_COMMIT_SHA ||
|
|
57
124
|
// GitLab CI
|
|
58
125
|
process.env.CIRCLE_SHA1 ||
|
|
59
126
|
// CircleCI
|
|
@@ -170,15 +237,30 @@ export function getPullRequestNumber() {
|
|
|
170
237
|
}
|
|
171
238
|
|
|
172
239
|
/**
|
|
173
|
-
* Get the PR head SHA from CI environment variables
|
|
240
|
+
* Get the PR head SHA from CI environment variables.
|
|
241
|
+
*
|
|
242
|
+
* For GitHub Actions, this reads from the event payload to get the actual
|
|
243
|
+
* head commit SHA, not the merge commit that GITHUB_SHA points to.
|
|
244
|
+
*
|
|
174
245
|
* @returns {string|null} PR head SHA or null if not available
|
|
175
246
|
*/
|
|
176
247
|
export function getPullRequestHeadSha() {
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
248
|
+
// Vizzly override always takes priority
|
|
249
|
+
if (process.env.VIZZLY_PR_HEAD_SHA) {
|
|
250
|
+
return process.env.VIZZLY_PR_HEAD_SHA;
|
|
251
|
+
}
|
|
252
|
+
|
|
253
|
+
// GitHub Actions: extract from event payload for PRs
|
|
254
|
+
if (process.env.GITHUB_ACTIONS) {
|
|
255
|
+
let event = getGitHubEvent();
|
|
256
|
+
if (event.pull_request?.head?.sha) {
|
|
257
|
+
return event.pull_request.head.sha;
|
|
258
|
+
}
|
|
259
|
+
return process.env.GITHUB_SHA || null;
|
|
260
|
+
}
|
|
261
|
+
|
|
262
|
+
// Other CI providers
|
|
263
|
+
return process.env.CI_COMMIT_SHA ||
|
|
182
264
|
// GitLab CI
|
|
183
265
|
process.env.CIRCLE_SHA1 ||
|
|
184
266
|
// CircleCI
|
|
@@ -200,13 +282,29 @@ export function getPullRequestHeadSha() {
|
|
|
200
282
|
}
|
|
201
283
|
|
|
202
284
|
/**
|
|
203
|
-
* Get the PR base SHA from CI environment variables
|
|
285
|
+
* Get the PR base SHA from CI environment variables.
|
|
286
|
+
*
|
|
287
|
+
* For GitHub Actions, this reads from the event payload to get the base
|
|
288
|
+
* branch SHA that the PR is targeting.
|
|
289
|
+
*
|
|
204
290
|
* @returns {string|null} PR base SHA or null if not available
|
|
205
291
|
*/
|
|
206
292
|
export function getPullRequestBaseSha() {
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
293
|
+
// Vizzly override always takes priority
|
|
294
|
+
if (process.env.VIZZLY_PR_BASE_SHA) {
|
|
295
|
+
return process.env.VIZZLY_PR_BASE_SHA;
|
|
296
|
+
}
|
|
297
|
+
|
|
298
|
+
// GitHub Actions: extract from event payload
|
|
299
|
+
if (process.env.GITHUB_ACTIONS) {
|
|
300
|
+
let event = getGitHubEvent();
|
|
301
|
+
if (event.pull_request?.base?.sha) {
|
|
302
|
+
return event.pull_request.base.sha;
|
|
303
|
+
}
|
|
304
|
+
}
|
|
305
|
+
|
|
306
|
+
// Other CI providers
|
|
307
|
+
return process.env.CI_MERGE_REQUEST_TARGET_BRANCH_SHA ||
|
|
210
308
|
// GitLab CI
|
|
211
309
|
null // Most CIs don't provide this
|
|
212
310
|
;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vizzly-testing/cli",
|
|
3
|
-
"version": "0.23.
|
|
3
|
+
"version": "0.23.2",
|
|
4
4
|
"description": "Visual review platform for UI developers and designers",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"visual-testing",
|
|
@@ -51,7 +51,6 @@
|
|
|
51
51
|
"files": [
|
|
52
52
|
"bin",
|
|
53
53
|
"dist",
|
|
54
|
-
"docs",
|
|
55
54
|
"claude-plugin",
|
|
56
55
|
"README.md",
|
|
57
56
|
"LICENSE"
|
|
@@ -1,270 +0,0 @@
|
|
|
1
|
-
# Vizzly Claude Code Plugin
|
|
2
|
-
|
|
3
|
-
> Integrate Vizzly visual regression testing seamlessly into your Claude Code workflow
|
|
4
|
-
|
|
5
|
-
This plugin brings Vizzly's powerful visual testing capabilities directly into Claude Code, helping you debug visual regressions, manage baselines, and integrate visual testing into your development workflow—all with AI assistance.
|
|
6
|
-
|
|
7
|
-
## Installation
|
|
8
|
-
|
|
9
|
-
### From GitHub (Recommended)
|
|
10
|
-
|
|
11
|
-
```bash
|
|
12
|
-
# Add the marketplace
|
|
13
|
-
/plugin marketplace add vizzly-testing/vizzly-cli
|
|
14
|
-
|
|
15
|
-
# Install the plugin
|
|
16
|
-
/plugin install vizzly@vizzly-marketplace
|
|
17
|
-
```
|
|
18
|
-
|
|
19
|
-
### From Local Source
|
|
20
|
-
|
|
21
|
-
```bash
|
|
22
|
-
# Clone the repository
|
|
23
|
-
git clone https://github.com/vizzly-testing/vizzly-cli.git
|
|
24
|
-
cd vizzly-cli
|
|
25
|
-
|
|
26
|
-
# Add the marketplace
|
|
27
|
-
/plugin marketplace add ./.claude-plugin
|
|
28
|
-
|
|
29
|
-
# Install the plugin
|
|
30
|
-
/plugin install vizzly@vizzly-marketplace
|
|
31
|
-
```
|
|
32
|
-
|
|
33
|
-
## Migration Guide (v0.0.x → v0.1.0)
|
|
34
|
-
|
|
35
|
-
**⚠️ Breaking Changes:** Slash commands for status checking and debugging have been replaced with Agent Skills.
|
|
36
|
-
|
|
37
|
-
### What Changed
|
|
38
|
-
|
|
39
|
-
**Before (v0.0.x):**
|
|
40
|
-
```bash
|
|
41
|
-
# Manually invoke slash commands
|
|
42
|
-
/vizzly:tdd-status
|
|
43
|
-
/vizzly:debug-diff homepage
|
|
44
|
-
```
|
|
45
|
-
|
|
46
|
-
**After (v0.1.0):**
|
|
47
|
-
```bash
|
|
48
|
-
# Just ask naturally - Skills activate automatically
|
|
49
|
-
"How are my visual tests?"
|
|
50
|
-
"The homepage screenshot is failing"
|
|
51
|
-
```
|
|
52
|
-
|
|
53
|
-
### Command Migration
|
|
54
|
-
|
|
55
|
-
| Old Slash Command | New Approach | How It Works |
|
|
56
|
-
|-------------------|--------------|--------------|
|
|
57
|
-
| `/vizzly:tdd-status` | Ask: "How are my tests?" | `check-visual-tests` Skill activates automatically |
|
|
58
|
-
| `/vizzly:debug-diff <name>` | Say: "Debug the homepage screenshot" | `debug-visual-regression` Skill activates automatically |
|
|
59
|
-
| `/vizzly:setup` | Still `/vizzly:setup` | ✅ No change - explicit setup workflow |
|
|
60
|
-
| `/vizzly:suggest-screenshots` | Still `/vizzly:suggest-screenshots` | ✅ No change - explicit suggestions workflow |
|
|
61
|
-
|
|
62
|
-
### Why This Change?
|
|
63
|
-
|
|
64
|
-
**Better UX:**
|
|
65
|
-
- No need to memorize command syntax
|
|
66
|
-
- Just describe what you need in natural language
|
|
67
|
-
- Claude understands your intent and activates the right Skill
|
|
68
|
-
- More intuitive and conversational workflow
|
|
69
|
-
|
|
70
|
-
**What Are Agent Skills?**
|
|
71
|
-
|
|
72
|
-
Agent Skills are model-invoked capabilities that Claude uses autonomously based on your request. Instead of explicitly typing `/command`, you simply ask questions or describe problems, and Claude will automatically use the appropriate Skill.
|
|
73
|
-
|
|
74
|
-
**Still Prefer Explicit Commands?**
|
|
75
|
-
|
|
76
|
-
You can still be explicit in your requests:
|
|
77
|
-
- "Check my Vizzly test status" → Activates `check-visual-tests` Skill
|
|
78
|
-
- "Debug the login screenshot failure" → Activates `debug-visual-regression` Skill
|
|
79
|
-
|
|
80
|
-
The Skills will activate based on your intent, not rigid command syntax.
|
|
81
|
-
|
|
82
|
-
## Features
|
|
83
|
-
|
|
84
|
-
### ✨ **Agent Skills** (Model-Invoked)
|
|
85
|
-
|
|
86
|
-
Claude automatically uses these Skills when you mention visual testing:
|
|
87
|
-
|
|
88
|
-
**🐛 Debug Visual Regression**
|
|
89
|
-
- Activated when you mention failing visual tests or screenshot differences
|
|
90
|
-
- Automatically analyzes visual changes, identifies root causes
|
|
91
|
-
- Compares baseline vs current screenshots
|
|
92
|
-
- Suggests whether to accept or fix changes
|
|
93
|
-
- Works with both local TDD and cloud modes
|
|
94
|
-
|
|
95
|
-
**🔍 Check Visual Test Status**
|
|
96
|
-
- Activated when you ask about test status or results
|
|
97
|
-
- Provides quick summary of passed/failed/new screenshots
|
|
98
|
-
- Shows diff percentages and threshold information
|
|
99
|
-
- Links to dashboard for detailed review
|
|
100
|
-
|
|
101
|
-
**Example usage:**
|
|
102
|
-
- Just say: *"The homepage screenshot is failing"* → Claude debugs it
|
|
103
|
-
- Just ask: *"How are my visual tests?"* → Claude checks status
|
|
104
|
-
- No slash commands needed—Claude activates Skills automatically!
|
|
105
|
-
|
|
106
|
-
### 📋 **Slash Commands** (User-Invoked)
|
|
107
|
-
|
|
108
|
-
Explicit workflows you trigger manually:
|
|
109
|
-
|
|
110
|
-
**⚡ Quick Setup**
|
|
111
|
-
- `/vizzly:setup` - Initialize Vizzly configuration
|
|
112
|
-
- Environment variable guidance
|
|
113
|
-
- CI/CD integration help
|
|
114
|
-
|
|
115
|
-
**💡 Screenshot Suggestions**
|
|
116
|
-
- `/vizzly:suggest-screenshots` - Analyze test files for screenshot opportunities
|
|
117
|
-
- Framework-specific code examples
|
|
118
|
-
- Respect your test structure and patterns
|
|
119
|
-
|
|
120
|
-
### Skills vs Slash Commands
|
|
121
|
-
|
|
122
|
-
**Skills** are capabilities Claude uses autonomously based on your request. Just describe what you need naturally, and Claude will use the appropriate Skill.
|
|
123
|
-
|
|
124
|
-
**Slash Commands** are explicit workflows you invoke manually when you want step-by-step guidance through a process.
|
|
125
|
-
|
|
126
|
-
## MCP Server Tools
|
|
127
|
-
|
|
128
|
-
The plugin provides an MCP server with direct access to Vizzly data:
|
|
129
|
-
|
|
130
|
-
### Local TDD Tools
|
|
131
|
-
- `detect_context` - Detect if using local TDD or cloud mode
|
|
132
|
-
- `get_tdd_status` - Get current TDD comparison results
|
|
133
|
-
- Parameters:
|
|
134
|
-
- `statusFilter` (optional): Filter by status - `'failed'`, `'new'`, `'passed'`, `'all'`, or `'summary'` (default)
|
|
135
|
-
- `limit` (optional): Maximum number of comparisons to return
|
|
136
|
-
- Default behavior (summary mode): Returns counts only without full comparison details for efficiency
|
|
137
|
-
- `read_comparison_details` - Detailed info for specific screenshot
|
|
138
|
-
- `accept_baseline` - Accept a screenshot as new baseline
|
|
139
|
-
- `reject_baseline` - Reject a baseline with reason
|
|
140
|
-
|
|
141
|
-
### Cloud API Tools
|
|
142
|
-
- `list_recent_builds` - List recent builds with filtering
|
|
143
|
-
- `get_build_status` - Get build status with commit context
|
|
144
|
-
- `get_comparison` - Get comparison details with screenshots
|
|
145
|
-
- `approve_comparison` - Approve a comparison with comment
|
|
146
|
-
- `reject_comparison` - Reject a comparison with reason
|
|
147
|
-
- `create_build_comment` - Add comment to build
|
|
148
|
-
|
|
149
|
-
## Authentication
|
|
150
|
-
|
|
151
|
-
The plugin automatically uses your Vizzly authentication with the following priority:
|
|
152
|
-
|
|
153
|
-
1. **Explicitly provided token** (via tool parameters)
|
|
154
|
-
2. **Environment variable** (`VIZZLY_TOKEN`)
|
|
155
|
-
3. **Project mapping** (configured via `vizzly project:select`)
|
|
156
|
-
4. **User access token** (from `vizzly login`)
|
|
157
|
-
|
|
158
|
-
### Getting Started
|
|
159
|
-
|
|
160
|
-
**For local development:**
|
|
161
|
-
```bash
|
|
162
|
-
vizzly login # Authenticate with your Vizzly account
|
|
163
|
-
vizzly project:select # Optional: set project-specific token
|
|
164
|
-
```
|
|
165
|
-
|
|
166
|
-
**For CI/CD:**
|
|
167
|
-
```bash
|
|
168
|
-
export VIZZLY_TOKEN=vzt_your_project_token
|
|
169
|
-
```
|
|
170
|
-
|
|
171
|
-
The plugin will automatically use the appropriate token based on your context.
|
|
172
|
-
|
|
173
|
-
## Requirements
|
|
174
|
-
|
|
175
|
-
- Claude Code
|
|
176
|
-
- Node.js 20+
|
|
177
|
-
- Vizzly CLI (`@vizzly-testing/cli`) installed in your project
|
|
178
|
-
- TDD mode running for local features
|
|
179
|
-
- Authentication configured (see above) for cloud features
|
|
180
|
-
|
|
181
|
-
## How It Works
|
|
182
|
-
|
|
183
|
-
### Agent Skills
|
|
184
|
-
|
|
185
|
-
The plugin's Skills use Claude Code's `allowed-tools` feature to restrict what actions they can perform:
|
|
186
|
-
|
|
187
|
-
**Check Visual Test Status Skill:**
|
|
188
|
-
- Can use: `get_tdd_status`, `detect_context`
|
|
189
|
-
- Purpose: Quickly check test status without modifying anything
|
|
190
|
-
|
|
191
|
-
**Debug Visual Regression Skill:**
|
|
192
|
-
- Can use: `Read`, `WebFetch`, `read_comparison_details`, `accept_baseline`, `approve_comparison`, `reject_comparison`
|
|
193
|
-
- Purpose: Analyze failures and suggest/apply fixes
|
|
194
|
-
|
|
195
|
-
### MCP Server Integration
|
|
196
|
-
|
|
197
|
-
The plugin bundles an MCP server that provides 15 tools for interacting with Vizzly:
|
|
198
|
-
|
|
199
|
-
- **Automatic startup** - MCP server starts when plugin is enabled
|
|
200
|
-
- **Token resolution** - Automatically finds your authentication token
|
|
201
|
-
- **Dual mode** - Works with both local TDD and cloud builds
|
|
202
|
-
- **No configuration needed** - Just install and use
|
|
203
|
-
|
|
204
|
-
## Troubleshooting
|
|
205
|
-
|
|
206
|
-
### Skills not activating
|
|
207
|
-
|
|
208
|
-
If Claude isn't using the Skills automatically:
|
|
209
|
-
|
|
210
|
-
1. Verify plugin is enabled: `/plugin`
|
|
211
|
-
2. Check MCP server status: `/mcp` (should show `plugin:vizzly:vizzly`)
|
|
212
|
-
3. Try being more explicit: "Check my Vizzly test status"
|
|
213
|
-
|
|
214
|
-
### MCP server not connecting
|
|
215
|
-
|
|
216
|
-
If the MCP server shows as "failed" in `/mcp`:
|
|
217
|
-
|
|
218
|
-
1. Check Node.js version: `node --version` (requires 20+)
|
|
219
|
-
2. View logs: `claude --debug`
|
|
220
|
-
3. Reinstall plugin: `/plugin uninstall vizzly@vizzly-marketplace` then `/plugin install vizzly@vizzly-marketplace`
|
|
221
|
-
|
|
222
|
-
### TDD server not found
|
|
223
|
-
|
|
224
|
-
If Skills report "TDD server not running":
|
|
225
|
-
|
|
226
|
-
1. Start TDD mode: `vizzly tdd start`
|
|
227
|
-
2. Verify server is running: Check for `.vizzly/server.json`
|
|
228
|
-
3. Run tests to generate screenshots
|
|
229
|
-
|
|
230
|
-
## Example Workflows
|
|
231
|
-
|
|
232
|
-
### Local TDD Development
|
|
233
|
-
|
|
234
|
-
```bash
|
|
235
|
-
# Start TDD server
|
|
236
|
-
vizzly tdd start
|
|
237
|
-
|
|
238
|
-
# Run your tests
|
|
239
|
-
npm test
|
|
240
|
-
|
|
241
|
-
# Ask Claude to check status
|
|
242
|
-
# "How are my visual tests?"
|
|
243
|
-
|
|
244
|
-
# If failures, ask Claude to debug
|
|
245
|
-
# "The login page screenshot is failing"
|
|
246
|
-
```
|
|
247
|
-
|
|
248
|
-
### Cloud Build Review
|
|
249
|
-
|
|
250
|
-
```bash
|
|
251
|
-
# After CI/CD runs and creates a build
|
|
252
|
-
# "Show me recent Vizzly builds"
|
|
253
|
-
|
|
254
|
-
# Review specific comparison
|
|
255
|
-
# "Analyze comparison cmp_abc123"
|
|
256
|
-
|
|
257
|
-
# Approve or reject
|
|
258
|
-
# Claude will suggest using approve/reject tools
|
|
259
|
-
```
|
|
260
|
-
|
|
261
|
-
## Documentation
|
|
262
|
-
|
|
263
|
-
- [Vizzly CLI](https://github.com/vizzly-testing/vizzly-cli) - Official CLI documentation
|
|
264
|
-
- [Vizzly Platform](https://vizzly.dev) - Web dashboard and cloud features
|
|
265
|
-
- [Claude Code](https://claude.com/claude-code) - Claude Code documentation
|
|
266
|
-
- [Agent Skills](https://docs.claude.com/en/docs/claude-code/skills) - Learn about Claude Code Skills
|
|
267
|
-
|
|
268
|
-
## License
|
|
269
|
-
|
|
270
|
-
MIT © Vizzly Team
|
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "vizzly-marketplace",
|
|
3
|
-
"owner": {
|
|
4
|
-
"name": "Vizzly Team",
|
|
5
|
-
"email": "team@vizzly.dev"
|
|
6
|
-
},
|
|
7
|
-
"metadata": {
|
|
8
|
-
"description": "Official Vizzly plugin for Claude Code - visual regression testing integration with TDD workflow support",
|
|
9
|
-
"version": "0.1.0"
|
|
10
|
-
},
|
|
11
|
-
"plugins": [
|
|
12
|
-
{
|
|
13
|
-
"name": "vizzly",
|
|
14
|
-
"source": "./",
|
|
15
|
-
"description": "Visual regression testing integration for Vizzly - TDD workflow support and debugging tools",
|
|
16
|
-
"version": "0.1.0",
|
|
17
|
-
"author": {
|
|
18
|
-
"name": "Vizzly Team",
|
|
19
|
-
"url": "https://vizzly.dev"
|
|
20
|
-
},
|
|
21
|
-
"homepage": "https://vizzly.dev",
|
|
22
|
-
"repository": "https://github.com/vizzly-testing/vizzly-cli",
|
|
23
|
-
"license": "MIT",
|
|
24
|
-
"keywords": ["visual-testing", "regression-testing", "tdd", "screenshot-testing", "vizzly"],
|
|
25
|
-
"category": "testing"
|
|
26
|
-
}
|
|
27
|
-
]
|
|
28
|
-
}
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "vizzly",
|
|
3
|
-
"version": "0.1.0",
|
|
4
|
-
"description": "Visual regression testing integration for Vizzly - TDD workflow support and debugging tools",
|
|
5
|
-
"author": {
|
|
6
|
-
"name": "Vizzly Team",
|
|
7
|
-
"url": "https://vizzly.dev"
|
|
8
|
-
},
|
|
9
|
-
"homepage": "https://vizzly.dev",
|
|
10
|
-
"repository": "https://github.com/vizzly-testing/cli",
|
|
11
|
-
"license": "MIT",
|
|
12
|
-
"keywords": ["visual-testing", "regression-testing", "tdd", "screenshot-testing", "vizzly"],
|
|
13
|
-
"mcpServers": "./.mcp.json"
|
|
14
|
-
}
|
package/claude-plugin/.mcp.json
DELETED
|
@@ -1,85 +0,0 @@
|
|
|
1
|
-
# Changelog
|
|
2
|
-
|
|
3
|
-
All notable changes to the Vizzly Claude Code plugin will be documented in this file.
|
|
4
|
-
|
|
5
|
-
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
|
6
|
-
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
7
|
-
|
|
8
|
-
## [Unreleased]
|
|
9
|
-
|
|
10
|
-
### Added
|
|
11
|
-
- 📚 **New MCP Server:** `vizzly-docs` - Easy access to Vizzly documentation
|
|
12
|
-
- `list_docs` - Browse all docs with optional category filtering
|
|
13
|
-
- `get_doc` - Retrieve full markdown content for any doc page
|
|
14
|
-
- `search_docs` - Keyword search across titles, descriptions, and categories
|
|
15
|
-
- `get_sidebar` - View complete documentation navigation structure
|
|
16
|
-
- Fetches from live docs.vizzly.dev site with intelligent caching
|
|
17
|
-
- ⚡️ **Performance:** `get_tdd_status` now supports filtering and pagination
|
|
18
|
-
- New `statusFilter` parameter: `'failed'`, `'new'`, `'passed'`, `'all'`, or `'summary'` (default)
|
|
19
|
-
- New `limit` parameter for capping number of comparisons returned
|
|
20
|
-
- Default behavior (summary mode) returns only counts for better token efficiency
|
|
21
|
-
- 🔧 **API Enhancement:** Cloud API provider now includes approval status and flaky screenshot detection
|
|
22
|
-
- Added approval status breakdown (pending/approved/rejected/auto_approved)
|
|
23
|
-
- Added flaky screenshot count
|
|
24
|
-
- Added hot spot coverage metadata for quick triage
|
|
25
|
-
|
|
26
|
-
### Changed
|
|
27
|
-
- 🔧 **Internal:** `acceptBaseline()` in TDD service now accepts both comparison ID (string) or full comparison object
|
|
28
|
-
- Enables accepting baselines from report-data.json without in-memory lookup
|
|
29
|
-
- Fixes issue where accepting from dashboard wasn't working properly
|
|
30
|
-
|
|
31
|
-
### Fixed
|
|
32
|
-
- 🐛 Fixed path bug in local TDD provider: `screenshots/` → `current/` directory
|
|
33
|
-
- 🐛 Fixed API field mapping in cloud provider: API returns `result` not `status`
|
|
34
|
-
|
|
35
|
-
## [0.1.0] - 2025-10-18
|
|
36
|
-
|
|
37
|
-
### Added
|
|
38
|
-
- ✨ **Agent Skills** - Model-invoked capabilities that activate autonomously
|
|
39
|
-
- `check-visual-tests` Skill - Automatically checks test status when you ask about tests
|
|
40
|
-
- `debug-visual-regression` Skill - Automatically analyzes failures when you mention visual issues
|
|
41
|
-
- 📦 MCP server configuration moved to plugin root (`.mcp.json`)
|
|
42
|
-
- 📝 Comprehensive README with Skills documentation, troubleshooting, and workflows
|
|
43
|
-
- 🔒 Tool restrictions via `allowed-tools` for better security and focused capabilities
|
|
44
|
-
|
|
45
|
-
### Changed
|
|
46
|
-
- 🔧 MCP server name: `vizzly-server` → `vizzly` (cleaner naming)
|
|
47
|
-
- 🔧 Skills use correct tool prefix: `mcp__plugin_vizzly_vizzly__*`
|
|
48
|
-
|
|
49
|
-
### Removed
|
|
50
|
-
- ❌ **BREAKING:** `/vizzly:tdd-status` slash command → Replaced by `check-visual-tests` Skill
|
|
51
|
-
- ❌ **BREAKING:** `/vizzly:debug-diff` slash command → Replaced by `debug-visual-regression` Skill
|
|
52
|
-
|
|
53
|
-
### Migration Guide
|
|
54
|
-
|
|
55
|
-
**Before (v0.0.x):**
|
|
56
|
-
```bash
|
|
57
|
-
# Manually invoke slash commands
|
|
58
|
-
/vizzly:tdd-status
|
|
59
|
-
/vizzly:debug-diff homepage
|
|
60
|
-
```
|
|
61
|
-
|
|
62
|
-
**After (v0.1.0):**
|
|
63
|
-
```bash
|
|
64
|
-
# Just ask naturally - Skills activate automatically
|
|
65
|
-
"How are my visual tests?"
|
|
66
|
-
"The homepage screenshot is failing"
|
|
67
|
-
```
|
|
68
|
-
|
|
69
|
-
**What Changed:**
|
|
70
|
-
- **Status checks** are now autonomous - just ask about your tests
|
|
71
|
-
- **Debugging** happens automatically when you mention failures
|
|
72
|
-
- **No need to remember slash commands** - Claude understands your intent
|
|
73
|
-
- **Setup and suggestions** still use slash commands (`/vizzly:setup`, `/vizzly:suggest-screenshots`)
|
|
74
|
-
|
|
75
|
-
**Why This Change:**
|
|
76
|
-
Agent Skills provide a more natural, intuitive experience. Instead of memorizing command syntax, you can ask questions in plain language and Claude will automatically use the right tools.
|
|
77
|
-
|
|
78
|
-
**If You Prefer Explicit Commands:**
|
|
79
|
-
While the slash commands are removed, you can still be explicit in your requests:
|
|
80
|
-
- "Check my Vizzly test status" → Activates `check-visual-tests` Skill
|
|
81
|
-
- "Debug the homepage screenshot" → Activates `debug-visual-regression` Skill
|
|
82
|
-
|
|
83
|
-
### Fixed
|
|
84
|
-
- MCP server location now follows Claude Code plugin specifications
|
|
85
|
-
- Tool naming consistency across Skills and MCP server
|