All skills
asyrafhussin avatar

/technical-debt

@4df703d

Technical debt inventory, prioritization, and audit for PHP/Laravel (MySQL) and Node/TypeScript/React projects. Use when assessing code health, identifying refactoring candidates, planning debt paydown, or auditing a codebase for accumulated debt. Triggers on "audit technical debt", "find tech debt", "debt inventory", "what should we refactor first", or tasks involving code health, security debt, performance debt, data debt, observability debt, debt prioritization, or remediation planning.

Use this Skill: https://skilld.dev/gh/asyrafhussin/agent-skills/technical-debt

This session only. Nothing lands on disk.

rulestest-disabled-tests.md

≈647 tokens on demand. Your agent reads this file only when SKILL.md points to it.

Skipped and Disabled Tests

Impact: HIGH (Dark coverage — code looks tested, isn't)

Skipped tests are worse than missing tests because they create a false sense of safety. A test.skip(...) or markTestSkipped() left in main without an owner, issue, or deadline is debt that grows in silence.

How to Detect

# JavaScript / TypeScript (Jest / Vitest)
grep -rEn '\\.skip|xdescribe|xit|test\\.todo|describe\\.skip' tests/ src/

# Pest / PHPUnit
grep -rEn 'markTestSkipped|markTestIncomplete|@group\\s+skip|->skip\\(' tests/

Cross-reference each hit with:

  • Is there a linked issue?
  • Is there a comment explaining why?
  • Is there a date or condition for re-enabling?

Incorrect

// ❌ Bare skips with no context
describe.skip('checkout', () => { /* ... */ });

test.skip('refunds work', () => { /* ... */ });

test('payment webhook', () => {
  if (process.env.CI) return;          // silent skip on CI
  // ...
});

Problems:

  • Why are checkouts skipped? Nobody remembers
  • The webhook test runs only locally — production behaviour is untested
  • Coverage report shows them as "executed" but with zero assertions

Correct

// ✅ Every skip has an owner, reason, and re-enable trigger
test.skip(
  'refunds work — DISABLED 2026-02-10 (#1247) re-enable after Stripe webhook v2 migration',
  () => { /* ... */ }
);

// ✅ Or: delete and replace if the test cannot be repaired
//   git log will remember it ever existed.

Add CI checks:

# .github/workflows/test-hygiene.yml
- name: Disallow new bare skips
  run: |
    NEW_SKIPS=$(git diff origin/main...HEAD -- 'tests/**' \
      | grep -E '^\+.*\.skip\(' | grep -v '#[0-9]')
    test -z "$NEW_SKIPS" || { echo "Bare skip without ticket"; exit 1; }

Benefits:

  • Every skip is auditable and assigned
  • New skips require a ticket — prevents quiet accumulation
  • The team has a count of "real" coverage

Remediation Strategy

  • Effort: S per skip (decide: fix, delete, or document)
  • When to pay down:
    • Now: audit existing skips → add owner + ticket OR delete
    • Ongoing: CI gate prevents new bare skips
  • Default action: if a skip is older than 90 days with no movement, delete the test. If it's worth keeping, it's worth re-enabling.

Reference: PHPUnit docs (see the "Incomplete and Skipped Tests" chapter in the current major version)

Source: SKILL.md on GitHub

No alerts16d3 checks · Risk SAFE
  • Gen Agent Trust Hub16d

    The skill provides a comprehensive and safe framework for identifying, prioritizing, and auditing technical debt in PHP/Laravel and Node/TypeScript/React projects. No security risks or malicious behaviors were detected.

  • Socket16d

    No alerts

  • Snyk16d

    Risk: LOW · No issues

Signed by skilld at 4df703d. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub last month.

Steadyupdated 5 months ago
metadata
{
  "author": "agent-skills",
  "version": "1.0.0"
}

README badge

README badge for asyrafhussin/agent-skills/technical-debt