smart-connections-ava-and-migration-harness

Installation
SKILL.md

Smart Connections AVA and Migration Harness

Use this skill when adding or updating focused Smart Connections regression coverage for utilities or migrations, especially when you need fixture-driven AVA tests and idempotent migration checks.

Critical

  • Keep the test file next to the code under test:
    • src/utils/build_connections_codeblock.test.js for utility regressions
    • migrations/migrate_hidden_connections.test.js for migration regressions
  • Import Ava with import test from 'ava'; and import the subject with an explicit .js extension.
  • Always cover:
    • the happy path
    • a no-op path (undefined, empty object/array, already-migrated input)
    • nested object assertions with t.deepEqual
  • Migration tests must verify idempotency: running the migration twice should return the same shape the second time.
  • Do not use snapshots or integration-style demos here. This skill is for isolated regression coverage only.

Instructions

  1. Identify the subject and create the test file in the matching directory:
    • src/utils/build_connections_codeblock.test.js for helpers such as build_connections_codeblock
    • migrations/migrate_hidden_connections.test.js for migration functions such as migrate_hidden_connections
Related skills
Installs
1
GitHub Stars
1
First Seen
Apr 16, 2026