Files
buzz/desktop/src-tauri
npub1223z34hd7vtwc6qj4s7flsxkj644nlre2nthu7lrrmkumhu3xddsrx9r6wandTaylor Ho e686f14407 test(desktop): cover agent-template listing, save upsert, and inbound echoes
Extract the pure cores of list_agent_templates (assemble_agent_templates)
and save_agent_as_template (upsert_template_persona) — behavior unchanged —
and pin them with unit tests: listing filters inactive and builtin-shadow
records and sorts saved templates case-insensitively after built-ins;
saving with an existing name updates the record in place (identity,
created_at, and stored env_vars preserved) instead of duplicating; a fresh
insert never carries credentials; and inactive or team-sourced records with
the same name are never hijacked. Also pin that an inbound persona echo
cannot resurrect a locally deactivated record — is_active is not a
projected field, so a stale relay echo leaves the local flag untouched.

Co-authored-by: Taylor Ho <taylorkmho@gmail.com>
Signed-off-by: Taylor Ho <taylorkmho@gmail.com>
2026-07-03 14:05:05 -07:00
..
2026-07-01 10:58:43 -07:00