fix: reformat withTimeout call and add unit test for timeout behavior

- Reformat withTimeout call to single line (prettier)
- Add unit test for CRD timeout behavior (crdAvailable=false when API fails)

Co-Authored-By: Paperclip <noreply@paperclip.ing>
This commit is contained in:
privilegedescalation-engineer
2026-03-25 07:18:19 +00:00
parent 0d5f65176b
commit 66932958b1
2 changed files with 26 additions and 4 deletions
+1 -4
View File
@@ -154,10 +154,7 @@ export function IntelGpuDataProvider({ children }: { children: React.ReactNode }
for (const url of pluginPodSelectors) {
try {
const list = await withTimeout(
ApiProxy.request(url),
DEFAULT_REQUEST_TIMEOUT_MS
);
const list = await withTimeout(ApiProxy.request(url), DEFAULT_REQUEST_TIMEOUT_MS);
if (!cancelled && isKubeList(list)) {
const gpuPluginPods = filterIntelGpuPluginPods(list.items);
foundPluginPods.push(...gpuPluginPods);