import { SyncController } from './sync.controller'; describe('SyncController — schedule sync options', () => { it('forwards the attendance-machine-only option', async () => { const syncService = { syncScheduleToDingTalk: jest.fn().mockResolvedValue({ syncedItems: 0 }), }; const controller = new SyncController(syncService as never); await (controller.syncSchedule as unknown as ( dateFrom?: string, days?: string, attendanceMachineOnly?: string, ) => Promise)('2026-07-10', '30', 'true'); expect(syncService.syncScheduleToDingTalk).toHaveBeenCalledWith( '2026-07-10', 30, true, ); }); });