()
| 1212 | |
| 1213 | // 测试所有代理 |
| 1214 | async function handleTestAllProxies() { |
| 1215 | elements.testAllProxiesBtn.disabled = true; |
| 1216 | elements.testAllProxiesBtn.innerHTML = '<span class="loading-spinner"></span> 测试中...'; |
| 1217 | |
| 1218 | try { |
| 1219 | const result = await api.post('/settings/proxies/test-all'); |
| 1220 | toast.info(`测试完成: 成功 ${result.success}, 失败 ${result.failed}`); |
| 1221 | loadProxies(); |
| 1222 | } catch (error) { |
| 1223 | toast.error('测试失败: ' + error.message); |
| 1224 | } finally { |
| 1225 | elements.testAllProxiesBtn.disabled = false; |
| 1226 | elements.testAllProxiesBtn.textContent = '🔌 测试全部'; |
| 1227 | } |
| 1228 | } |
| 1229 | |
| 1230 | |
| 1231 | // ============================================================================ |
nothing calls this directly
no test coverage detected