(filePath: string)
| 388 | } |
| 389 | const alphaDecoderCache = new Map<string, Promise<boolean>>(); |
| 390 | const shouldUseVp9AlphaDecoder = (filePath: string): Promise<boolean> => { |
| 391 | if (!extractMediaMetadata) return Promise.resolve(false); |
| 392 | const cached = alphaDecoderCache.get(filePath); |
| 393 | if (cached) return cached; |
| 394 | const pending = extractMediaMetadata(filePath) |
| 395 | .then((meta) => meta.hasAlpha && meta.videoCodec === "vp9") |
| 396 | .catch(() => false); |
| 397 | alphaDecoderCache.set(filePath, pending); |
| 398 | return pending; |
| 399 | }; |
| 400 | |
| 401 | const hasPlayer = await page.evaluate(() => !!(window as any).__player); |
| 402 | if (!hasPlayer) { |
no test coverage detected