import { describe, expect, it } from 'vitest';
import { pendingApproval } from './platform-command';

describe('平台命令提交结果', () => {
  it('识别需要四眼审批的 202 业务响应', () => {
    expect(pendingApproval({ executionStatus: 'pending_approval', approvalRequest: { id: 'approval-1' } }))
      .toMatchObject({ approvalRequest: { id: 'approval-1' } });
  });

  it('即时执行结果不进入审批提示', () => {
    expect(pendingApproval({ executionStatus: 'executed', result: {} })).toBeNull();
  });
});
