

Also from Kynth Studios


Also from Kynth Studios


Also from Kynth Studios
1# Scripts23## e2e-share.sh45End-to-end integration tests for the crit CLI to crit-web share flow. Tests the full round-trip: sharing reviews, fetching web comments, re-sharing without duplicates, and unpublishing.67### Prerequisites89- A local crit-web checkout as a sibling directory (`../crit-web` relative to the crit repo root, or set `CRIT_WEB_DIR`)10- PostgreSQL running locally (the script creates a `crit_e2e` database)11- mise (for Go and Elixir toolchain management)1213### Usage1415```bash16# Full run: build crit, start crit-web on :4001, run tests, tear down17make e2e-share18# or directly:19./scripts/e2e-share.sh2021# Start crit-web for manual testing (Ctrl+C to stop)22./scripts/e2e-share.sh --serve2324# Run tests against an already-running crit-web25./scripts/e2e-share.sh --skip-web2627# Run a specific test28./scripts/e2e-share.sh -run TestShareSyncFullLifecycle29```3031### Environment variables3233| Variable | Default | Description |34|---|---|---|35| `CRIT_WEB_PORT` | `4001` | Port for the test crit-web instance |36| `CRIT_WEB_DIR` | `../crit-web` | Path to crit-web checkout |37| `DB_NAME` | `crit_e2e` | PostgreSQL database name (separate from dev) |3839### What the script does40411. Builds crit via `make build`422. Creates/resets the `crit_e2e` database433. Starts crit-web with `SELFHOSTED=true` on the test port (no OAuth)444. Waits for `GET /health` to return 200455. Runs all `TestShareSync*` integration tests with `CRIT_AUTH_TOKEN=""` to bypass any local auth config466. Tears down crit-web on exit4748### Test file: `share_integration_test.go`4950Build tag: `//go:build integration` — these tests are excluded from `go test ./...` and only run via `go test -tags integration`.5152Tests use `--output <dir>` to write `.crit.json` to a temp directory (not `~/.crit/reviews/`), and `--share-url` to point at the local crit-web instance.5354Every test logs its review URL (`t.Logf(" -> Review: ...")`) so you can open them in a browser for visual inspection. Reviews persist on crit-web after tests run (except the unpublish test).5556#### Test cases5758| Test | What it covers |59|---|---|60| `TestShareSyncIntegration` | Original: share, seed web comment, re-share, verify content + export |61| `TestShareSyncNoComments` | Share with zero comments, verify document on web |62| `TestShareSyncLineComments` | Line-scoped comments: body, position, scope verified on web |63| `TestShareSyncFileComment` | File-scoped comment: body, scope, file_path verified on web |64| `TestShareSyncReviewLevelComments` | Review-level comments shared (tests #297 fix for CLI path) |65| `TestShareSyncMixedCommentTypes` | All 3 scopes together, each verified on web |66| `TestShareSyncResolvedExcluded` | Resolved comments filtered out of share payload |67| `TestShareSyncReshareNoDuplicates` | Re-share preserves comments without duplication |68| `TestShareSyncReshareNoChanges` | No-op when content unchanged (round stays same) |69| `TestShareSyncFetchWebComments` | Web-authored comments pulled into local .crit.json |70| `TestShareSyncFetchWebCommentsNoDuplicates` | Repeated syncs don't duplicate web comments |71| `TestShareSyncMultipleFiles` | Multi-file share with per-file comment association |72| `TestShareSyncMultipleRounds` | Round progression across 3 share cycles, content verified |73| `TestShareSyncCommentWithReplies` | Threaded replies included in share |74| `TestShareSyncUnpublish` | Full unpublish: web deletion + local state cleared |75| `TestShareSyncExport` | Export endpoint returns .crit.json-compatible shape |76| `TestShareSyncFetchReviewLevelWebComment` | Review-level web comments merged into local ReviewComments |77| `TestShareSyncFullLifecycle` | Complete round-trip: local comments with threads, share, web comments added, fetch, re-share (preserved), fetch again (no duplicates) |7879#### Adding new tests8081- Name test functions `TestShareSync*` so they're picked up by the `-run TestShareSync` filter82- Use the helpers: `critShareCmd`, `critUnpublishCmd`, `writeTestCritJSON`, `readCritJSON`, `commentsFromAPI`, `documentFromAPI`, `seedComment`, `seedCommentAt`, `seedReviewComment`, `logReview`, `extractToken`83- Always call `logReview(t, output)` after sharing so the URL is visible in test output84- Use `writeTestCritJSON` (not `writeCritJSON` — that name conflicts with `github.go`)8586## e2e-roundtrip.sh and e2e-gitlab-roundtrip.sh8788These are the provider-specific runners for one live roundtrip suite in `internal/session`. GitHub uses the `e2e_github` tag, `CRIT_ROUNDTRIP_REPO`, and authenticated `gh`; GitLab uses the `e2e_gitlab` tag, `CRIT_GITLAB_ROUNDTRIP_PROJECT`, and authenticated `glab` (plus optional `CRIT_GITLAB_ROUNDTRIP_HOST` for self-managed instances). Both create and clean up a temporary change request and branch. See `test/roundtrip/README.md` for shared setup and authoring guidance.89
One repository carrying more than one format is the comparison this product exists for: does anyone actually write different content in each file, or is one a copy of the other?
| Repository | Format | Stack | Covers | Score | Changed |
|---|---|---|---|---|---|
| tomasz-tomczyk/crit.cursor/rules/frontend-architecture.mdc · 903 | Cursor rules | archgitdo-not | 65/100 | today | |
| tomasz-tomczyk/crit.cursor/rules/frontend-css.mdc · 903 | Cursor rules | uido-not | 46/100 | today | |
| tomasz-tomczyk/crit.cursor/rules/frontend-js.mdc · 903 | Cursor rules | lint-formatstyletesting-strategyui+1 | 59/100 | today | |
| tomasz-tomczyk/crit.cursor/rules/go.mdc · 903 | Cursor rules | teststylegitdo-not | 67/100 | today | |
| tomasz-tomczyk/crit.cursor/rules/proxy-auth-transport.mdc · 903 | Cursor rules | securitydo-not | 50/100 | today | |
| tomasz-tomczyk/critAGENTS.md · 903 | AGENTS.md | buildtestlint-formatstyle+2 | 77/100 | today |
Same format, overlapping stack, ranked by quality.
| Repository | Format | Stack | Covers | Score | Changed |
|---|---|---|---|---|---|
| n8n-io/n8npackages/@n8n/agents/AGENTS.md · 201k | AGENTS.md | buildteststylearch+3 | 100/100 | 14 days ago | |
| duckduckgo/content-scope-scriptsspecial-pages/AGENTS.md · 70 | AGENTS.md | buildteststylearch+3 | 100/100 | 14 days ago | |
| code-yeongyu/oh-my-openagentpackages/web/AGENTS.md · 68k | AGENTS.md | setupbuildtestlint-format+6 | 100/100 | 13 days ago | |
| TryGhost/Ghoste2e/AGENTS.md · 55k | AGENTS.md | setupteststylearch+2 | 100/100 | today | |
| mui/material-uiAGENTS.md · 99k | AGENTS.md | setupbuildtestlint-format+9 | 100/100 | 14 days ago | |
| ethereum/go-ethereumAGENTS.md · 51k | AGENTS.md | buildtestlint-formatgit+1 | 100/100 | 14 days ago | |
| rails/railsAGENTS.md · 59k | AGENTS.md | teststylearchgit+4 | 100/100 | 14 days ago | |
| bagisto/bagistoAGENTS.md · 28k | AGENTS.md | setupbuildteststyle+7 | 100/100 | 7 days ago |
A badge carrying the measured quality of the strongest agent config file in this repository, out of 100. It reads from this index every time somebody loads your page, so it changes when the measurement changes and there is nothing to keep up to date. Free, no account, and the value is not something you or we can set by hand.
[](https://rulestack.kynth.studio/configs/tomasz-tomczyk-crit-scripts-agents)Would rather not hotlink us? Every badge is also served in shields.io’s endpoint schema, so shields renders the image and your readers never talk to our domain:
Published by Toolproof, the masthead over this index and eight others. The method behind the number is at toolproof.kynth.studio/methodology, and the whole thing is readable as JSON with no key at /api.