Skip to content

Commit b6b712f

Browse files
committed
feat(scripts/feature-coverage): add --list option
1 parent eb9c557 commit b6b712f

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

scripts/feature-coverage.ts

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -257,6 +257,12 @@ const main = (bcd: CompatData, tests: Tests) => {
257257
type: "string",
258258
default: "collector-from-bcd",
259259
})
260+
.option("list", {
261+
alias: "l",
262+
describe: "List all features supported by the collector",
263+
type: "boolean",
264+
default: false
265+
})
260266
.option("path", {
261267
alias: "p",
262268
describe: "The path(s) to filter for",
@@ -273,6 +279,13 @@ const main = (bcd: CompatData, tests: Tests) => {
273279
},
274280
);
275281

282+
if (argv.list) {
283+
Object.keys(tests).filter(
284+
(p) => !p.startsWith("__"),
285+
).forEach(key => console.log(key));
286+
return;
287+
}
288+
276289
const direction = argv.direction.split("-from-");
277290

278291
if (!argv.countOnly) {

0 commit comments

Comments
 (0)