This commit is contained in:
2025-05-23 21:20:39 +00:00
parent 9629329bc2
commit 0907949f8a
86 changed files with 654 additions and 569 deletions

View File

@ -1,6 +1,6 @@
import { tap, expect } from '@git.zone/tstest/tapbundle';
import * as net from 'net';
import { startTestServer, stopTestServer } from '../server.loader.js';
import { startTestServer, stopTestServer } from '../../helpers/server.loader.js';
import type { SmtpServer } from '../../../ts/mail/delivery/smtpserver/index.js';
const TEST_PORT = 2525;
@ -71,7 +71,7 @@ tap.test('Abrupt Disconnection - should handle socket destruction without QUIT',
setTimeout(() => resolve(false), 5000);
});
expect(recoveryConnected).toBeTrue();
expect(recoveryConnected).toEqual(true);
if (recoveryConnected) {
// Get banner from recovery connection
@ -143,7 +143,7 @@ tap.test('Abrupt Disconnection - should handle multiple simultaneous abrupt disc
setTimeout(() => resolve(false), 5000);
});
expect(stillAccepting).toBeTrue();
expect(stillAccepting).toEqual(true);
if (stillAccepting) {
const banner = await new Promise<string>((resolve) => {
@ -240,7 +240,7 @@ tap.test('Abrupt Disconnection - should handle disconnection during DATA transfe
setTimeout(() => resolve(false), 5000);
});
expect(canConnect).toBeTrue();
expect(canConnect).toEqual(true);
if (canConnect) {
const banner = await new Promise<string>((resolve) => {
@ -307,7 +307,7 @@ tap.test('Abrupt Disconnection - should timeout idle connections', async (tools)
}
// Either behavior is acceptable
expect(true).toBeTrue();
expect(true).toEqual(true);
} finally {
done.resolve();
@ -316,7 +316,7 @@ tap.test('Abrupt Disconnection - should timeout idle connections', async (tools)
tap.test('cleanup - stop SMTP server', async () => {
await stopTestServer();
expect(true).toBeTrue();
expect(true).toEqual(true);
});
tap.start();