本文へ移動
cccskills
無料GitHub で公開

fix-test

Debug and fix failing tests systematically

インストール方法を見る

含まれるファイル(1)

  • SKILL.md1.4 KB

SKILL.md(原文)

インストールする前に、エージェントに与えられる指示の中身を確認できます。

Fix Test

Systematically debug and fix failing test(s).

Workflow

1. Identify Failures

./bashunit tests/ 2>&1

Parse: which files, which functions, error messages.

2. Categorize Each Failure

  • Test bug — test itself is wrong (wrong expected value, bad setup)
  • Implementation bug — code doesn't match expected behavior
  • Environment issue — missing dependency, wrong fixture path
  • Race condition — passes sequential, fails parallel
  • Flaky test — network/time/random dependency

3. Fix

  • Test bug: correct assertion or setup
  • Implementation bug: minimal fix in src/, follow TDD
  • Environment: fix set_up / fixtures
  • Race condition: use $temp_dir for isolation, wait for async
  • Flaky: mock external dependencies

4. Verify

./bashunit path/to/fixed_test.sh        # Specific test
./bashunit tests/                        # Full suite
./bashunit --parallel tests/             # Isolation check

5. Prevent Regression

Document root cause. Consider adding edge case tests to prevent recurrence.

Debugging Tips

  • Use --filter "test_name" to run single test
  • Add echo "DEBUG: $var" >&2 temporarily
  • Check fixtures exist: ls tests/fixtures/
  • Verify mocks: assert_have_been_called mock_name

レビュー

まだレビューはありません。使ってみた感想をお寄せください。

同じリポジトリのスキル

概要と使いどころ

Add new assertion function with comprehensive tests following TDD

日本語の概要は準備中です。原文の説明を表示しています。

TypedDevs/bashunit4342026年10月10日 更新

Analyze test coverage and identify untested code paths

日本語の概要は準備中です。原文の説明を表示しています。

TypedDevs/bashunit4342026年10月10日 更新

commit

無料

Stage and commit changes using conventional commits format

日本語の概要は準備中です。原文の説明を表示しています。

TypedDevs/bashunit4342026年10月10日 更新

gh-issue

無料

Fetch GitHub issue, create branch, plan and implement with TDD, then open PR

日本語の概要は準備中です。原文の説明を表示しています。

TypedDevs/bashunit4342026年10月10日 更新

gh-issues

無料

Walk over all open GitHub issues that are unassigned or assigned to the current user, and process each one via the /gh-issue skill, sequentially.

日本語の概要は準備中です。原文の説明を表示しています。

TypedDevs/bashunit4342026年10月10日 更新

pr

無料

Push branch and create a GitHub PR with concise, issue-linked description

日本語の概要は準備中です。原文の説明を表示しています。

TypedDevs/bashunit4342026年10月10日 更新

TypedDevs のスキルをすべて見る

このスキルの問題を報告する