test(ui): cover miner-commands redaction and action branches (#8677) - #8716
test(ui): cover miner-commands redaction and action branches (#8677)#8716andriypolanski wants to merge 1 commit into
Conversation
…ed#8677) Add a dedicated unit test for sanitizeMinerCommand and buildMinerCommandActions so public-surface sensitive-term redaction cannot regress silently. Co-authored-by: Cursor <cursoragent@cursor.com>
|
Superagent didn't find any vulnerabilities or security issues in this PR. |
|
Caution 🛑 LoopOver review result - fixes requiredReview updated: 2026-07-26 00:35:46 UTC
Review summary Nits — 4 non-blocking
CI checks failing
Decision drivers
Context & advisory signals — never blocks the verdict
Linked issue satisfactionAddressed Review context
Contributor next steps
Signal definitions
🧪 Chat with LoopOverAsk LoopOver a question about this PR directly in a comment — grounded only in the same cached, public-safe facts shown above, never a new claim.
Full command reference: https://loopover.ai/docs/loopover-commands 🧪 Experimental — new and may change. 🟩 Safe / merged · 🟦 Advisory · 🟨 Held for review · 🟥 Blocked / closed 💰 Earn for open-source contributions like this. Gittensor lets GitHub contributors earn for the work they already do — register to start earning →. Checked by LoopOver, a quiet PR intelligence layer for OSS maintainers.
|
|
LoopOver is closing this pull request on the maintainer's behalf (CI is failing (validate, validate-code)). This is an automated maintenance action — to pursue this change, please open a new pull request with the issues resolved. Closed PRs may be analyzed later to improve review accuracy, but they are not automatically reopened or re-reviewed. |
Summary
apps/loopover-ui/src/lib/miner-commands.test.tswith direct coverage ofsanitizeMinerCommand(each forbiddenterm=valuecategory, passthrough, path redaction, no false-positive on bare login/repo tokens) andbuildMinerCommandActions(setup/ready/needs_login/needs_repo branches, invalid login/repo fallbacks).sanitizeMinerCommandso the redaction contract can be regression-tested without going throughminer-panel.Scope
type(scope): short summaryConventional Commit format, for examplefix(api): restore profile access checks.CONTRIBUTING.mdand does not reintroduce GitHub Pages, VitePress,site/, orCNAME.Closes #123) — a linked open issue is required for every contributor PR.Validation
git diff --checknpm run actionlintnpm run typecheckvitest run src/lib/miner-commands.test.ts(fromapps/loopover-ui) — 10 passedminer-commands.ts: 100% statements / branches / functions / linesnpm run test:coveragenpm run ui:testnpm run ui:lintnpm run ui:typechecknpm run ui:buildnpm audit --audit-level=moderateIf any required check was skipped, explain why:
Test-only change under
apps/**(not Codecov-gated). Fulltest:ci/ UI matrix left for the opener if desired before push; targeted vitest + coverage above satisfy the issue’s full-branch requirement.UI Evidence
N/A — test-only; no visible UI/frontend change.
Notes for reviewers / gate
term=valueredaction.site/,CNAME,**/lovable/**, orCHANGELOG.md.