import { describe, it, expect } from 'vitest';
import { buildReviewCommentBody } from '../github/client.js';
describe('buildReviewCommentBody', () => {
    it('renders Claude thorough with model and custom service in the header and annotation', () => {
        const body = buildReviewCommentBody({
            body: 'VERDICT: APPROVE',
            reviewer: 'claude',
            brand: { service_name: 'Acme' },
            origin: 'codex',
            verdict: 'APPROVE',
            model: 'claude-opus-4-7',
            stepType: 'review',
            round: 2,
            sha: 'abc1234',
        });
        expect(body).toContain('### Code Review by 🤖 Claude Code · Opus 4.7 · Acme');
        expect(body).toContain('model=claude-opus-4-7 type=review round=2 verdict=APPROVE service=Acme sha=abc1234');
    });
    it('omits model and service segments for default Codex subscription auth', () => {
        const body = buildReviewCommentBody({
            body: 'VERDICT: NEEDS_WORK',
            reviewer: 'codex',
            brand: { service_name: 'crosscheck' },
            origin: 'claude',
            verdict: 'NEEDS_WORK',
            model: 'default',
            stepType: 'review',
        });
        expect(body).toContain('### Code Review by ⚡ Codex\n\n');
        expect(body).not.toContain(' · ');
        expect(body).toContain('model=default');
    });
    it('renders recheck and fix step verbs', () => {
        const recheck = buildReviewCommentBody({
            body: 'VERDICT: APPROVE',
            reviewer: 'codex',
            verdict: 'APPROVE',
            model: 'o4-mini',
            stepType: 'recheck',
            replyToCommentId: 123,
        });
        const fix = buildReviewCommentBody({
            body: 'fixed',
            reviewer: 'claude',
            verdict: 'APPROVE',
            model: 'claude-sonnet-4-6',
            stepType: 'fix',
        });
        expect(recheck).toContain('> Recheck of [original review](#issuecomment-123)');
        expect(recheck).toContain('### Recheck by ⚡ Codex · o4-mini');
        expect(fix).toContain('### Fixes by 🤖 Claude Code · Sonnet 4.6');
    });
});
//# sourceMappingURL=review-comment-body.test.js.map