* Filter betas to only include those in the allowlist. * Returns allowed and disallowed betas separately.
(betas: string[])
| 41 | * Returns allowed and disallowed betas separately. |
| 42 | */ |
| 43 | function partitionBetasByAllowlist(betas: string[]): { |
| 44 | allowed: string[] |
| 45 | disallowed: string[] |
| 46 | } { |
| 47 | const allowed: string[] = [] |
| 48 | const disallowed: string[] = [] |
| 49 | for (const beta of betas) { |
| 50 | if (ALLOWED_SDK_BETAS.includes(beta)) { |
| 51 | allowed.push(beta) |
| 52 | } else { |
| 53 | disallowed.push(beta) |
| 54 | } |
| 55 | } |
| 56 | return { allowed, disallowed } |
| 57 | } |
| 58 | |
| 59 | /** |
| 60 | * Filter SDK betas to only include allowed ones. |
no test coverage detected