feat(ai): add ADR-036 unified OCR architecture and frontend test coverage
- Add ADR-036 unified OCR architecture (typhoon-ocr via Ollama) - Extend AI execution profiles for OCR sandbox configuration - Add comprehensive frontend test coverage (components, hooks, services) - Add backend test coverage for document-numbering services - Update OCR sidecar with typhoon-ocr integration - Add AI policy service and execution profile management - Update AGENTS.md and architecture documentation
This commit is contained in:
@@ -156,6 +156,17 @@ describe('DocumentNumberingService', () => {
|
||||
'Transaction failed'
|
||||
);
|
||||
});
|
||||
|
||||
it('should throw error when format fails', async () => {
|
||||
(counterService.incrementCounter as jest.Mock).mockResolvedValue(1);
|
||||
(formatService.format as jest.Mock).mockRejectedValue(
|
||||
new Error('Format failed')
|
||||
);
|
||||
|
||||
await expect(service.generateNextNumber(mockContext)).rejects.toThrow(
|
||||
'Format failed'
|
||||
);
|
||||
});
|
||||
});
|
||||
|
||||
describe('Admin Operations', () => {
|
||||
|
||||
Reference in New Issue
Block a user