@vizzly-testing/cli 0.23.1 → 0.24.0
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.css +1 -1
- package/dist/reporter/reporter-bundle.iife.js +71 -63
- package/dist/server/handlers/tdd-handler.js +4 -9
- package/dist/tdd/core/region-coverage.js +115 -0
- package/dist/tdd/core/signature.js +3 -1
- package/dist/tdd/metadata/region-metadata.js +93 -0
- package/dist/tdd/services/comparison-service.js +40 -8
- package/dist/tdd/services/region-service.js +75 -0
- package/dist/tdd/tdd-service.js +70 -8
- package/package.json +3 -4
- 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/docs/upload-command.md
DELETED
|
@@ -1,196 +0,0 @@
|
|
|
1
|
-
# Upload Command Guide
|
|
2
|
-
|
|
3
|
-
The `vizzly upload` command is the simplest way to get started with Vizzly. It uploads screenshots directly from a directory without requiring test integration.
|
|
4
|
-
|
|
5
|
-
## Basic Usage
|
|
6
|
-
|
|
7
|
-
```bash
|
|
8
|
-
vizzly upload <path>
|
|
9
|
-
```
|
|
10
|
-
|
|
11
|
-
Upload all screenshots from a directory:
|
|
12
|
-
|
|
13
|
-
```bash
|
|
14
|
-
vizzly upload ./screenshots
|
|
15
|
-
vizzly upload ./test-results/screenshots
|
|
16
|
-
vizzly upload ./cypress/screenshots
|
|
17
|
-
```
|
|
18
|
-
|
|
19
|
-
## Options
|
|
20
|
-
|
|
21
|
-
### Build Information
|
|
22
|
-
|
|
23
|
-
**`--build-name <name>`** - Custom build name
|
|
24
|
-
```bash
|
|
25
|
-
vizzly upload ./screenshots --build-name "Release v1.2.3"
|
|
26
|
-
vizzly upload ./screenshots --build-name "PR-456"
|
|
27
|
-
```
|
|
28
|
-
|
|
29
|
-
**`--environment <env>`** - Environment name (default: "test")
|
|
30
|
-
```bash
|
|
31
|
-
vizzly upload ./screenshots --environment "staging"
|
|
32
|
-
vizzly upload ./screenshots --environment "production"
|
|
33
|
-
```
|
|
34
|
-
|
|
35
|
-
### Git Integration
|
|
36
|
-
|
|
37
|
-
The CLI automatically detects git information, but you can override:
|
|
38
|
-
|
|
39
|
-
**`--branch <branch>`** - Git branch override
|
|
40
|
-
```bash
|
|
41
|
-
vizzly upload ./screenshots --branch "feature/new-ui"
|
|
42
|
-
```
|
|
43
|
-
|
|
44
|
-
**`--commit <sha>`** - Git commit SHA override
|
|
45
|
-
```bash
|
|
46
|
-
vizzly upload ./screenshots --commit "abc123def456"
|
|
47
|
-
```
|
|
48
|
-
|
|
49
|
-
**`--message <msg>`** - Commit message override
|
|
50
|
-
```bash
|
|
51
|
-
vizzly upload ./screenshots --message "Fix header layout"
|
|
52
|
-
```
|
|
53
|
-
|
|
54
|
-
### Comparison Settings
|
|
55
|
-
|
|
56
|
-
**`--threshold <number>`** - Comparison threshold (0-1, default: 0.01)
|
|
57
|
-
```bash
|
|
58
|
-
vizzly upload ./screenshots --threshold 0.05 # More tolerant
|
|
59
|
-
vizzly upload ./screenshots --threshold 0.001 # More strict
|
|
60
|
-
```
|
|
61
|
-
|
|
62
|
-
### Processing
|
|
63
|
-
|
|
64
|
-
**`--wait`** - Wait for build completion
|
|
65
|
-
```bash
|
|
66
|
-
vizzly upload ./screenshots --wait
|
|
67
|
-
```
|
|
68
|
-
|
|
69
|
-
This will:
|
|
70
|
-
- Upload all screenshots
|
|
71
|
-
- Wait for processing to complete
|
|
72
|
-
- Show progress and results
|
|
73
|
-
- Exit with appropriate status code
|
|
74
|
-
|
|
75
|
-
**`--upload-all`** - Upload all screenshots without SHA deduplication
|
|
76
|
-
```bash
|
|
77
|
-
vizzly upload ./screenshots --upload-all
|
|
78
|
-
```
|
|
79
|
-
|
|
80
|
-
By default, Vizzly deduplicates screenshots based on their SHA hash to avoid unnecessary uploads. Use this flag to force upload of all screenshots regardless of their content.
|
|
81
|
-
|
|
82
|
-
**`--metadata <json>`** - Additional metadata as JSON
|
|
83
|
-
```bash
|
|
84
|
-
vizzly upload ./screenshots --metadata '{"browser": "chrome", "viewport": "1920x1080"}'
|
|
85
|
-
```
|
|
86
|
-
|
|
87
|
-
## Examples
|
|
88
|
-
|
|
89
|
-
### Basic Upload
|
|
90
|
-
```bash
|
|
91
|
-
# Simple upload with auto-detected git info
|
|
92
|
-
vizzly upload ./screenshots
|
|
93
|
-
```
|
|
94
|
-
|
|
95
|
-
### Release Build
|
|
96
|
-
```bash
|
|
97
|
-
# Upload with specific build name and wait for results
|
|
98
|
-
vizzly upload ./screenshots \
|
|
99
|
-
--build-name "Release v2.1.0" \
|
|
100
|
-
--environment "production" \
|
|
101
|
-
--wait
|
|
102
|
-
```
|
|
103
|
-
|
|
104
|
-
### CI/CD Integration
|
|
105
|
-
```bash
|
|
106
|
-
# Upload with CI-specific metadata
|
|
107
|
-
vizzly upload ./test-results/screenshots \
|
|
108
|
-
--build-name "CI-Build-${BUILD_NUMBER}" \
|
|
109
|
-
--branch "${GIT_BRANCH}" \
|
|
110
|
-
--commit "${GIT_COMMIT}" \
|
|
111
|
-
--message "${GIT_COMMIT_MESSAGE}" \
|
|
112
|
-
--wait
|
|
113
|
-
```
|
|
114
|
-
|
|
115
|
-
### Manual Testing
|
|
116
|
-
```bash
|
|
117
|
-
# Upload with custom metadata for manual test session
|
|
118
|
-
vizzly upload ./manual-screenshots \
|
|
119
|
-
--build-name "Manual Test Session" \
|
|
120
|
-
--metadata '{"tester": "john.doe", "device": "iPhone 13"}' \
|
|
121
|
-
--environment "staging"
|
|
122
|
-
```
|
|
123
|
-
|
|
124
|
-
## File Support
|
|
125
|
-
|
|
126
|
-
The upload command supports:
|
|
127
|
-
|
|
128
|
-
- **PNG files** - Primary format for screenshots
|
|
129
|
-
- **JPG/JPEG files** - Also supported
|
|
130
|
-
- **Recursive directory scanning** - Finds images in subdirectories
|
|
131
|
-
- **Automatic filtering** - Ignores non-image files
|
|
132
|
-
|
|
133
|
-
## Build Processing
|
|
134
|
-
|
|
135
|
-
When you upload screenshots, Vizzly:
|
|
136
|
-
|
|
137
|
-
1. **Creates a build** - Groups your screenshots together
|
|
138
|
-
2. **Finds baselines** - Matches against previous approved screenshots
|
|
139
|
-
3. **Generates comparisons** - Creates visual diffs for changed screenshots
|
|
140
|
-
4. **Provides results** - Shows what changed, what's new, what's approved
|
|
141
|
-
|
|
142
|
-
## Status Codes
|
|
143
|
-
|
|
144
|
-
The upload command exits with different status codes:
|
|
145
|
-
|
|
146
|
-
- **0** - Success (all screenshots approved or no changes)
|
|
147
|
-
- **1** - Changes detected (requires review)
|
|
148
|
-
- **2** - Upload failed or error occurred
|
|
149
|
-
|
|
150
|
-
This makes it perfect for CI/CD pipelines where you want the build to fail if visual changes are detected.
|
|
151
|
-
|
|
152
|
-
## Common Workflows
|
|
153
|
-
|
|
154
|
-
### First Time Setup
|
|
155
|
-
```bash
|
|
156
|
-
# Upload initial baseline screenshots
|
|
157
|
-
vizzly upload ./screenshots --build-name "Initial Baseline"
|
|
158
|
-
```
|
|
159
|
-
|
|
160
|
-
### Regular Development
|
|
161
|
-
```bash
|
|
162
|
-
# Upload after making changes
|
|
163
|
-
vizzly upload ./screenshots --build-name "Feature: New Dashboard"
|
|
164
|
-
```
|
|
165
|
-
|
|
166
|
-
### Release Process
|
|
167
|
-
```bash
|
|
168
|
-
# Upload release candidate screenshots
|
|
169
|
-
vizzly upload ./screenshots \
|
|
170
|
-
--build-name "Release Candidate v2.0" \
|
|
171
|
-
--environment "production" \
|
|
172
|
-
--wait
|
|
173
|
-
```
|
|
174
|
-
|
|
175
|
-
## Troubleshooting
|
|
176
|
-
|
|
177
|
-
**No screenshots found**
|
|
178
|
-
- Check the path exists and contains image files
|
|
179
|
-
- Verify file permissions
|
|
180
|
-
- Use absolute paths if relative paths aren't working
|
|
181
|
-
|
|
182
|
-
**Upload failed**
|
|
183
|
-
- Verify your API token is set: `echo $VIZZLY_TOKEN`
|
|
184
|
-
- Check network connectivity
|
|
185
|
-
- Try with `--verbose` for detailed error information
|
|
186
|
-
|
|
187
|
-
**Slow uploads**
|
|
188
|
-
- Large image files take longer to upload
|
|
189
|
-
- Network speed affects upload time
|
|
190
|
-
- Use `--wait` to see progress information
|
|
191
|
-
|
|
192
|
-
## Next Steps
|
|
193
|
-
|
|
194
|
-
- Learn about [Test Integration](./test-integration.md) for automated screenshot capture
|
|
195
|
-
- Explore [TDD Mode](./tdd-mode.md) for local development
|
|
196
|
-
- Check the [API Reference](./api-reference.md) for programmatic usage
|