fix: 增加2925邮箱登录超时和重试逻辑,优化用户体验

This commit is contained in:
QLHazyCoder
2026-04-22 02:35:13 +08:00
parent 83c26460c7
commit 4128cbda3c
6 changed files with 20 additions and 8 deletions
@@ -8,6 +8,13 @@ test('background mail2925 session uses /login/ as relogin entry url', () => {
assert.match(source, /const MAIL2925_LOGIN_URL = 'https:\/\/2925\.com\/login\/';/);
});
test('background mail2925 session keeps login message timeout above the 40-second mailbox wait', () => {
const source = fs.readFileSync('background/mail-2925-session.js', 'utf8');
assert.match(source, /timeoutMs:\s*50000,/);
assert.match(source, /responseTimeoutMs:\s*50000,/);
assert.match(source, /40 秒内未进入收件箱/);
});
test('ensureMail2925MailboxSession waits 3 seconds before and after opening login page on force relogin', async () => {
const source = fs.readFileSync('background/mail-2925-session.js', 'utf8');
const globalScope = {};