docs: fix agent instructions — coverage thresholds and PR quality rules#277
Merged
docs: fix agent instructions — coverage thresholds and PR quality rules#277
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub. |
There was a problem hiding this comment.
Pull request overview
Updates contributor/agent guidance to reflect the repo’s actual coverage enforcement and PR-quality expectations, reducing CI failures caused by following outdated instructions.
Changes:
- Corrected documented Vitest coverage thresholds to match
vitest.config.ts. - Updated pre-push / pre-PR checklist commands to use
npm run test:coverage(aligned with CI). - Added PR-quality checklist items (description fidelity, HTTP status handling, secret redaction).
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
agents.md |
Fixes coverage threshold guidance, updates test command to test:coverage, and adds PR-quality checklist rules. |
.github/copilot-instructions.md |
Aligns Copilot instructions with CI by requiring test:coverage and documenting the correct thresholds. |
…mand, PR quality rules - Fix incorrect coverage threshold (was 80%, actual is 75/74/75/75) - Change 'npm test' to 'npm run test:coverage' in checklist (CI enforces thresholds) - Add rules: PR descriptions must match implementation - Add rules: always check HTTP response status (fetch resolves on 4xx/5xx) - Add rules: never expose secrets in API responses Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
1b46c39 to
7e226e8
Compare
The envOverrides.indexing spread was missing from the config merge, so LIBSCOPE_ALLOW_PRIVATE_URLS and LIBSCOPE_ALLOW_SELF_SIGNED_CERTS environment variables were silently ignored. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Add tests across low-coverage files to exceed the 74% branch threshold: - Create db-validation.test.ts: full coverage of validateRow/validateCountRow - schema.test.ts: add createVectorTable edge cases and migration error wrapping - search.test.ts: add LIKE fallback filter tests (version, minRating, dates, source, tags, maxChunksPerDocument, contextChunks), FTS filter tests - rag.test.ts: add Ollama/OpenAI provider error branches, token counting, default models, empty choices, status code handling - packs.test.ts: add validation edge cases for metadata fields, description, version, documents array type - graph.test.ts: add multi-chunk embedding averaging test - watcher.test.ts: add non-file stat, missing filename, non-Error events, missing document on delete Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Cover importFromBackup error branches: non-object backup, missing keys, non-array documents, invalid document structure, missing metadata version, and non-JSON file handling. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes incorrect/missing guidance in agent instruction files that led to CI failures across PRs #274, #275, #276.
Changes
npm test→npm run test:coveragein checklist (CI runstest:coveragewhich enforces thresholds;npm testdoes not)test:coveragefix with threshold values