Problem
A linked test's metadata (note, timeout_seconds, path, scope) cannot be changed in place. The only route is to remove the entry and re-add it:
pm test pm-github-9cjx --remove-index 1
pm test pm-github-9cjx --add-json '{"command":"npm run coverage","path":"scripts/coverage-gate.ts","scope":"project","timeout_seconds":900,"note":"Exact 100/100/100/100 gate …"}'
That has real costs for agents keeping trackers accurate:
- The agent must restate every field. A forgotten
path or timeout_seconds is silently dropped.
- The entry moves to the end of
--list order, so a later --only-index N or --remove-index N in a script or prompt now targets a different test.
- The original
provenance (author, created_at, source_ref) is replaced by the editor's. The record of who linked the test, and when, is lost.
- History shows a removal plus an addition rather than an edit, which reads as a different test.
This came up in a code review: a reviewer bot flagged that a linked test note still said "this item remains open until it measures … exact 100" after the gate passed. Notes like this go stale whenever work completes, and every tracker hygiene pass has to work around it.
Proposal
pm test <id> --update <selector> --set note=… [--set timeout_seconds=…], or --update-index <n> --note …, that:
- edits only the named fields, keeping position and the original
provenance, plus an updated_by / updated_at pair;
- records one
test_updated history event with a field-level diff;
- refuses selectors that match zero or several entries, with the candidates listed (like
--remove);
- has an SDK equivalent (
updateLinkedTest) so extensions can maintain their own receipts.
Acceptance
- Changing a note keeps the entry's
--list index and original provenance.
- History shows a single update event naming the changed fields.
- An ambiguous or empty selector is refused, with no mutation.
Problem
A linked test's metadata (
note,timeout_seconds,path,scope) cannot be changed in place. The only route is to remove the entry and re-add it:That has real costs for agents keeping trackers accurate:
pathortimeout_secondsis silently dropped.--listorder, so a later--only-index Nor--remove-index Nin a script or prompt now targets a different test.provenance(author, created_at, source_ref) is replaced by the editor's. The record of who linked the test, and when, is lost.This came up in a code review: a reviewer bot flagged that a linked test note still said "this item remains open until it measures … exact 100" after the gate passed. Notes like this go stale whenever work completes, and every tracker hygiene pass has to work around it.
Proposal
pm test <id> --update <selector> --set note=… [--set timeout_seconds=…], or--update-index <n> --note …, that:provenance, plus anupdated_by/updated_atpair;test_updatedhistory event with a field-level diff;--remove);updateLinkedTest) so extensions can maintain their own receipts.Acceptance
--listindex and original provenance.