fix(quick-261005-d5d): Postfach-Abruf ueber EWS mit 60-s-Zeitgrenze
Gleicher eigener Timer wie im Kalender; httpreqs timeout greift waehrend des Verbindungsaufbaus nicht. 60 s, weil PDF-Anhaenge geladen werden. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -128,6 +128,24 @@ beforeEach(() => {
|
||||
httpntlmPost.mockClear();
|
||||
});
|
||||
|
||||
describe('ExchangeInboxProvider — Zeitgrenze (quick-261005)', () => {
|
||||
it('testConnection meldet nach 60 s ohne Antwort „nicht erreichbar“ statt zu haengen', async () => {
|
||||
vi.useFakeTimers();
|
||||
try {
|
||||
httpntlmPost.mockImplementation(() => {
|
||||
/* ruft nie zurueck — wie ein unbeantworteter Verbindungsaufbau */
|
||||
});
|
||||
const pending = new ExchangeInboxProvider().testConnection(BASE_CONFIG);
|
||||
await vi.advanceTimersByTimeAsync(60_000);
|
||||
const result = await pending;
|
||||
expect(result.success).toBe(false);
|
||||
expect(result.message).toContain('not reachable');
|
||||
} finally {
|
||||
vi.useRealTimers();
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
describe('ExchangeInboxProvider.fetchMessages', () => {
|
||||
it('a BodyType="HTML" GetItem response yields bodyHtml populated and bodyText empty', async () => {
|
||||
mockEwsFlow(getItemHtmlResponse());
|
||||
|
||||
Reference in New Issue
Block a user