saffron-ai 0.7.0 → 0.7.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/CHANGELOG.md +127 -1
- package/README.md +12 -10
- package/dist-pkg/cli.js +111 -103
- package/package.json +3 -3
- package/skills/saffron/SKILL.md +5 -3
- package/skills/saffron/references/config.md +3 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "saffron-ai",
|
|
3
|
-
"version": "0.7.
|
|
3
|
+
"version": "0.7.2",
|
|
4
4
|
"description": "Gherkin-native AI-fallback test runner: zero-token cached replay, runtime AI healing, honest reports",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"test": "vitest run",
|
|
@@ -46,9 +46,9 @@
|
|
|
46
46
|
"vscode-languageserver-textdocument": "^1.0.12",
|
|
47
47
|
"zod": "^4.4.3"
|
|
48
48
|
},
|
|
49
|
-
"homepage": "https://saffron-ai.
|
|
49
|
+
"homepage": "https://saffron-ai.io",
|
|
50
50
|
"bugs": {
|
|
51
|
-
"url": "https://github.com/s-chathuranga-j/saffron-
|
|
51
|
+
"url": "https://github.com/s-chathuranga-j/saffron-community/issues"
|
|
52
52
|
},
|
|
53
53
|
"engines": {
|
|
54
54
|
"node": ">=20"
|
package/skills/saffron/SKILL.md
CHANGED
|
@@ -4,7 +4,7 @@ description: Write, run, and maintain end-to-end UI tests with Saffron, a Gherki
|
|
|
4
4
|
license: Saffron Free Use License v1.0 (see the saffron-ai package LICENSE)
|
|
5
5
|
metadata:
|
|
6
6
|
author: saffron-ai
|
|
7
|
-
homepage: https://saffron-ai.
|
|
7
|
+
homepage: https://saffron-ai.io
|
|
8
8
|
---
|
|
9
9
|
|
|
10
10
|
# Saffron
|
|
@@ -12,8 +12,10 @@ metadata:
|
|
|
12
12
|
Saffron runs plain-Gherkin scenarios in a real browser. There are **no
|
|
13
13
|
step definitions and no glue code**: on the first run an AI agent performs
|
|
14
14
|
each step and records what it did into a JSON cache; every later run
|
|
15
|
-
|
|
16
|
-
|
|
15
|
+
is replayed by Saffron in a real browser: zero AI calls, zero tokens, at
|
|
16
|
+
the speed of the browser and the app. (The cache is Saffron's own JSON, run
|
|
17
|
+
on Playwright's browser engine; Playwright MCP is used only by the agent
|
|
18
|
+
while recording and healing.) When the UI drifts, the agent heals the failing
|
|
17
19
|
step mid-run and files a reviewable proposal.
|
|
18
20
|
|
|
19
21
|
Your job when writing tests is to make that economy work. Three rules
|
|
@@ -11,6 +11,7 @@ your-project/
|
|
|
11
11
|
proposals/ pending AI proposals → review, then gone
|
|
12
12
|
history.jsonl one line per run (trends) → commit recommended
|
|
13
13
|
reports/ latest.html / latest.json → git-ignore
|
|
14
|
+
artifacts/ failure screenshots (latest run) → git-ignore
|
|
14
15
|
```
|
|
15
16
|
|
|
16
17
|
## `saffron.config.json`
|
|
@@ -22,6 +23,7 @@ your-project/
|
|
|
22
23
|
"actionTimeoutMs": 5000,
|
|
23
24
|
"pollIntervalMs": 100,
|
|
24
25
|
"retries": 1,
|
|
26
|
+
"screenshot": "viewport",
|
|
25
27
|
"model": "claude-sonnet-5",
|
|
26
28
|
"healModel": "claude-haiku-4-5",
|
|
27
29
|
"maxTurns": 100,
|
|
@@ -42,6 +44,7 @@ your-project/
|
|
|
42
44
|
| `storageState` | Playwright storage-state JSON so replays and the agent start authenticated (`npx playwright open --save-storage=.auth/state.json <url>`) |
|
|
43
45
|
| `actionTimeoutMs` | Budget for one action: Playwright's actionability wait and the deadline for a polled assertion (default 5000) |
|
|
44
46
|
| `pollIntervalMs` | How often a polled assertion re-checks the page inside that budget (default 100, minimum 10) |
|
|
47
|
+
| `screenshot` | Screenshot of the failing tab when a step fails: `viewport` (default), `full-page`, `off`. Shown in the report; paths in `latest.json` under `evidence`; files in `.saffron/artifacts/` (git-ignore it) |
|
|
45
48
|
| `retries` | Extra attempts per action with backoff before a step fails and the agent heals (default 1). Not a scenario re-run; reports show a `retried ×N` chip |
|
|
46
49
|
| `strict` | Yellow (passed-with-adaptation) exits 1 until reviewed: cached-green-only CI |
|
|
47
50
|
| `assertionPolicy` | `strict` (default) or `adaptable-mid`; the final assertion block is always strict |
|