From e2cc1220ec1e0afdb4fbbbb2774e2ec030e8ab13 Mon Sep 17 00:00:00 2001 From: Claas Augner Date: Tue, 7 Oct 2025 11:45:09 +0200 Subject: [PATCH] feat(scripts/feature-coverage): add --list option --- scripts/feature-coverage.ts | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/scripts/feature-coverage.ts b/scripts/feature-coverage.ts index 1554c981f..891ef909c 100644 --- a/scripts/feature-coverage.ts +++ b/scripts/feature-coverage.ts @@ -269,6 +269,12 @@ const main = (bcd: CompatData, tests: Tests) => { type: "string", default: "collector-from-bcd", }) + .option("list", { + alias: "l", + describe: "List all features supported by the collector", + type: "boolean", + default: false, + }) .option("path", { alias: "p", describe: "The path(s) to filter for", @@ -285,6 +291,13 @@ const main = (bcd: CompatData, tests: Tests) => { }, ); + if (argv.list) { + Object.keys(tests) + .filter((p) => !p.startsWith("__")) + .forEach((key) => console.log(key)); + return; + } + const direction = argv.direction.split("-from-"); if (!argv.countOnly) {