checkwright 0.46.0 → 0.47.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/package.json +2 -2
- package/payload/artifact/aarch64-apple-darwin/checkwright-gates +0 -0
- package/payload/artifact/aarch64-apple-darwin/checkwright-gates.sha256 +1 -1
- package/payload/artifact/aarch64-pc-windows-msvc/checkwright-gates.exe +0 -0
- package/payload/artifact/aarch64-pc-windows-msvc/checkwright-gates.exe.sha256 +1 -1
- package/payload/artifact/aarch64-unknown-linux-gnu/checkwright-gates +0 -0
- package/payload/artifact/aarch64-unknown-linux-gnu/checkwright-gates.sha256 +1 -1
- package/payload/artifact/aarch64-unknown-linux-musl/checkwright-gates +0 -0
- package/payload/artifact/aarch64-unknown-linux-musl/checkwright-gates.sha256 +1 -1
- package/payload/artifact/x86_64-apple-darwin/checkwright-gates +0 -0
- package/payload/artifact/x86_64-apple-darwin/checkwright-gates.sha256 +1 -1
- package/payload/artifact/x86_64-pc-windows-msvc/checkwright-gates.exe +0 -0
- package/payload/artifact/x86_64-pc-windows-msvc/checkwright-gates.exe.sha256 +1 -1
- package/payload/artifact/x86_64-unknown-linux-gnu/checkwright-gates +0 -0
- package/payload/artifact/x86_64-unknown-linux-gnu/checkwright-gates.sha256 +1 -1
- package/payload/artifact/x86_64-unknown-linux-musl/checkwright-gates +0 -0
- package/payload/artifact/x86_64-unknown-linux-musl/checkwright-gates.sha256 +1 -1
- package/payload/canon-kit/README.md +1 -0
- package/payload/canon-kit/checks/check-duplicate-text.gate +4 -0
- package/payload/canon-kit/gate-tests/check-duplicate-text/bad/docs/a.md +7 -0
- package/payload/canon-kit/gate-tests/check-duplicate-text/bad/docs/b.md +6 -0
- package/payload/canon-kit/gate-tests/check-duplicate-text/bad/docs/c.md +6 -0
- package/payload/canon-kit/gate-tests/check-duplicate-text/bad/expect.txt +4 -0
- package/payload/canon-kit/gate-tests/check-duplicate-text/bad/scripts/canon-config.knobs +3 -0
- package/payload/canon-kit/gate-tests/check-duplicate-text/good/docs/a.md +22 -0
- package/payload/canon-kit/gate-tests/check-duplicate-text/good/docs/b.md +19 -0
- package/payload/canon-kit/gate-tests/check-duplicate-text/good/expect.txt +1 -0
- package/payload/canon-kit/gate-tests/check-duplicate-text/good/scripts/canon-config.knobs +3 -0
- package/payload/canon-kit/gate-tests/check-duplicate-text.test.sh +77 -0
package/package.json
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
"checkwright-pwsh": "bin/checkwright.ps1"
|
|
5
5
|
},
|
|
6
6
|
"checkwright": {
|
|
7
|
-
"commit": "
|
|
7
|
+
"commit": "ad6c6774c3128bf4d0957a135f52deafd712205f",
|
|
8
8
|
"spec_base_url": "https://checkwright.dev"
|
|
9
9
|
},
|
|
10
10
|
"description": "Reproducible checks that catch unsupported claims in coding-agent delivery before merge: a task marked done with no recorded test run, a skipped lifecycle stage, a spec naming a file the tree lacks. They prove the evidence a claim rests on exists, not that the code is correct.",
|
|
@@ -30,5 +30,5 @@
|
|
|
30
30
|
"type": "git",
|
|
31
31
|
"url": "git+https://github.com/checkwright/checkwright.git"
|
|
32
32
|
},
|
|
33
|
-
"version": "0.
|
|
33
|
+
"version": "0.47.0"
|
|
34
34
|
}
|
|
Binary file
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
791f6dfc535312ae8dfc1af09c85efa73ecdd78d4ea4e463fde9f0f93d2a8587 checkwright-gates
|
|
Binary file
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
3c7d2a573129aa4777a59383e82795083326031c171365fb375460e93b6e16cc *checkwright-gates.exe
|
|
Binary file
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
a8921540f0ef44b75ae4ada811dbeb5adb64c93e1c71a9de8f37211b77d55aa5 checkwright-gates
|
|
Binary file
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
78ee0d39acea197ab9fd2ee07f956d3551c01fb2526814aa2a6a9946c7c6869a checkwright-gates
|
|
Binary file
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
42dfbdfaca965c4f2bddaa1f3bbc93ecd43ed6c4d92cc964f9623fe01ca83d9f checkwright-gates
|
|
Binary file
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
1f63ed45ecc718d5d1840dba5225a8d01b961ce454fe67c605cd9a9e16a688c8 *checkwright-gates.exe
|
|
Binary file
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
63ca18878f098db10361cb32489c6830f2315bfffbe445d1da09007f4731a154 checkwright-gates
|
|
Binary file
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
4b652a268f92e88a6e6cdade186e58c62c5a67c37b8aa2be4dde3c785072b6bd checkwright-gates
|
|
@@ -27,6 +27,7 @@ Vendor the kit beside [gate-sdk](../gate-sdk/) (required); the queue-facing gate
|
|
|
27
27
|
check-docs-cmd # invoked paths + kit knobs in docs resolve
|
|
28
28
|
check-docs-restatement-parity # needs restating pages (their code tokens held to the README beside each)
|
|
29
29
|
check-docs-page-repeat # needs declared pages (no link target or long sentence stated twice on one, or restated from the chrome)
|
|
30
|
+
check-duplicate-text # needs declared files (no long run of words stated in two of them)
|
|
30
31
|
check-docs-page-length # needs declared pages and a bound (no page past the word bound)
|
|
31
32
|
check-citation-link # needs declared pages (every section citation links its section)
|
|
32
33
|
check-fence-command-head # every shell-fence command starts with a word that can run
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
# graph: couples=knob:CANON_KIT_DUPLICATE_TEXT_GLOBS dir=one valve=none tier=precommit
|
|
2
|
+
# install: zero-config
|
|
3
|
+
# armed-by: CANON_KIT_DUPLICATE_TEXT_GLOBS
|
|
4
|
+
# spec: canon-kit/SPEC.md §check-duplicate-text — no run of CANON_KIT_DUPLICATE_TEXT_MIN_WORDS words or more is stated in two declared files, with the duplicate-text-exempt valve
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
docs/b.md:3: a run of 11 words first stated at docs/a.md:3: "every commit runs the full battery …"
|
|
2
|
+
docs/b.md:6: a run of 13 words first stated at docs/a.md:5: "the shared run starts here on …"
|
|
3
|
+
docs/c.md:3: a run of 11 words first stated at docs/a.md:3: "every commit runs the full battery …"
|
|
4
|
+
docs/c.md:6: a run of 11 words first stated at docs/a.md:7: "a reasonless valve never exempts the …" (its duplicate-text-exempt valve carries no reason)
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: the front matter both pages carry word for word
|
|
3
|
+
---
|
|
4
|
+
# Alpha
|
|
5
|
+
|
|
6
|
+
Alpha opens with quick brown foxes jumping over the fence.
|
|
7
|
+
|
|
8
|
+
```sh
|
|
9
|
+
bash gate-sdk/bin/run-gates.sh --only check-duplicate-text runs this same fenced command
|
|
10
|
+
```
|
|
11
|
+
|
|
12
|
+
See [the owning section](https://example.com/one/two/three/four/five/six) first.
|
|
13
|
+
|
|
14
|
+
<!-- roster:begin -->
|
|
15
|
+
this generated block restates the same words in every file it is written into
|
|
16
|
+
<!-- roster:end -->
|
|
17
|
+
|
|
18
|
+
Every reader runs the battery before each commit lands on the branch.
|
|
19
|
+
|
|
20
|
+
A rule repeated in two units of one file under the default setting passes.
|
|
21
|
+
|
|
22
|
+
- A rule repeated in two units of one file under the default setting passes.
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: the front matter both pages carry word for word
|
|
3
|
+
---
|
|
4
|
+
# Beta
|
|
5
|
+
|
|
6
|
+
Beta closes on quick brown foxes jumping over a wall.
|
|
7
|
+
|
|
8
|
+
```sh
|
|
9
|
+
bash gate-sdk/bin/run-gates.sh --only check-duplicate-text runs this same fenced command
|
|
10
|
+
```
|
|
11
|
+
|
|
12
|
+
Read [it](https://example.com/one/two/three/four/five/six) before you start.
|
|
13
|
+
|
|
14
|
+
<!-- roster:begin -->
|
|
15
|
+
this generated block restates the same words in every file it is written into
|
|
16
|
+
<!-- roster:end -->
|
|
17
|
+
|
|
18
|
+
<!-- duplicate-text-exempt: the reader of this page needs the rule here, in full -->
|
|
19
|
+
Every reader runs the battery before each commit lands on the branch.
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
DUPLICATE-TEXT: clean (2 file(s), 7 unit(s); no run of 6 words or more stated in two files)
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
#!/usr/bin/env bash
|
|
2
|
+
# Behavioral test of the arms the one-pair good/bad harness cannot hold: the
|
|
3
|
+
# within-file switch turned on, the exclude knob dropping a file from the
|
|
4
|
+
# comparison, and the exit-3 refusal of an unreadable declared file.
|
|
5
|
+
#
|
|
6
|
+
# Run by the --run-gate-tests arm (any <tests-dir>/*.test.sh; must exit 0).
|
|
7
|
+
set -uo pipefail
|
|
8
|
+
source "$(dirname "${BASH_SOURCE[0]}")/../../gate-sdk/lib/test-hermetic.sh"
|
|
9
|
+
|
|
10
|
+
DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd)" # canon-kit/
|
|
11
|
+
SANDBOX="$(mktemp -d)"
|
|
12
|
+
trap 'chmod -R u+rwx "$SANDBOX" 2>/dev/null; rm -rf "$SANDBOX"' EXIT
|
|
13
|
+
|
|
14
|
+
fails=0
|
|
15
|
+
|
|
16
|
+
cat >"$SANDBOX/a.md" <<'EOF'
|
|
17
|
+
# A
|
|
18
|
+
|
|
19
|
+
The battery runs on every commit before it lands.
|
|
20
|
+
|
|
21
|
+
- The battery runs on every commit before it lands.
|
|
22
|
+
EOF
|
|
23
|
+
cat >"$SANDBOX/b.md" <<'EOF'
|
|
24
|
+
# B
|
|
25
|
+
|
|
26
|
+
A page of its own, with nothing in common.
|
|
27
|
+
EOF
|
|
28
|
+
cat >"$SANDBOX/gates.knobs" <<'EOF'
|
|
29
|
+
CANON_KIT_DUPLICATE_TEXT_GLOBS[] = *.md
|
|
30
|
+
CANON_KIT_DUPLICATE_TEXT_MIN_WORDS = 6
|
|
31
|
+
EOF
|
|
32
|
+
|
|
33
|
+
run() { # $1..=extra env assignments; prints output, returns rc
|
|
34
|
+
(cd "$SANDBOX" && gate_env CANON_KIT_KNOB_FILE="$SANDBOX/gates.knobs" "$@" \
|
|
35
|
+
&& gate_run check-duplicate-text "$DIR/checks" 2>&1)
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
check_case() { # $1=label $2=want-rc $3=want-substring $4=output $5=rc
|
|
39
|
+
if [[ "$5" -ne "$2" ]]; then
|
|
40
|
+
echo " FAIL [$1]: want exit $2, got $5 -- $4"; fails=$((fails + 1)); return
|
|
41
|
+
fi
|
|
42
|
+
if [[ -n "$3" ]] && ! grep -qF -- "$3" <<<"$4"; then
|
|
43
|
+
echo " FAIL [$1]: exit $5 OK but output lacks '$3':"; printf ' %s\n' "$4"
|
|
44
|
+
fails=$((fails + 1))
|
|
45
|
+
fi
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
out="$(run)"; rc=$?
|
|
49
|
+
check_case "within-file-off" 0 "no run of 6 words or more stated in two files" "$out" "$rc"
|
|
50
|
+
|
|
51
|
+
out="$(run CANON_KIT_DUPLICATE_TEXT_WITHIN_FILE=on)"; rc=$?
|
|
52
|
+
check_case "within-file-on" 1 "a.md:5: a run of 9 words first stated at a.md:3" "$out" "$rc"
|
|
53
|
+
|
|
54
|
+
cp "$SANDBOX/a.md" "$SANDBOX/c.md"
|
|
55
|
+
out="$(run)"; rc=$?
|
|
56
|
+
check_case "copy-compared" 1 "c.md:3: a run of 9 words first stated at a.md:3" "$out" "$rc"
|
|
57
|
+
|
|
58
|
+
printf '%s\n' 'CANON_KIT_DUPLICATE_TEXT_EXCLUDE[] = c.md' >>"$SANDBOX/gates.knobs"
|
|
59
|
+
out="$(run)"; rc=$?
|
|
60
|
+
check_case "exclude-drops-the-copy" 0 "DUPLICATE-TEXT: clean (2 file(s)" "$out" "$rc"
|
|
61
|
+
|
|
62
|
+
# A tree where the sandbox owner can read what it just made unreadable proves
|
|
63
|
+
# nothing, so the refusal is probed before it is asserted.
|
|
64
|
+
chmod 000 "$SANDBOX/b.md"
|
|
65
|
+
if cat "$SANDBOX/b.md" >/dev/null 2>&1; then
|
|
66
|
+
echo " SKIP [unreadable-file-fails-closed]: this user reads a 0000 file"
|
|
67
|
+
else
|
|
68
|
+
out="$(run)"; rc=$?
|
|
69
|
+
check_case "unreadable-file-fails-closed" 3 "b.md" "$out" "$rc"
|
|
70
|
+
fi
|
|
71
|
+
|
|
72
|
+
if [[ "$fails" -gt 0 ]]; then
|
|
73
|
+
echo "check-duplicate-text.test.sh: $fails case(s) failed"
|
|
74
|
+
exit 1
|
|
75
|
+
fi
|
|
76
|
+
echo "check-duplicate-text.test.sh: clean (within-file off + on + a compared copy + the exclude knob + an unreadable file)"
|
|
77
|
+
exit 0
|