テストコードを生成
Generates unit, integration, and E2E tests for backend code with mocks and best practices.
/plugin marketplace add childbamboo/claude-code-marketplace-sample/plugin install backend@claude-code-marketplace-sample既存のAPIエンドポイント、サービス、関数に対するテストコードを自動生成します。
テストを生成したい対象を指定してください:
対応するフレームワーク:
describe('POST /api/users', () => {
it('creates a new user with valid data', async () => {
// 正常系テスト
});
it('returns 400 when email is invalid', async () => {
// バリデーションエラーテスト
});
it('returns 401 when not authenticated', async () => {
// 認証エラーテスト
});
});
describe('UserService', () => {
it('creates user and sends welcome email', async () => {
// ビジネスロジックテスト
});
it('throws error when email already exists', async () => {
// エラーケーステスト
});
});
以下のモックを自動生成します:
テストを生成したい対象を教えてください。