fix(lint): Deno.lint.runPlugin throws in deno run (#28063)

This commit changes `Deno.lint.runPlugin` to throw
in non-`deno test` subcommand, instead of returning
`undefined`.
This commit is contained in:
Bartek Iwańczuk 2025-02-12 10:18:55 +01:00 committed by GitHub
parent 3ff9ca2533
commit d29f9f99dd
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
6 changed files with 43 additions and 2 deletions

View file

@ -1487,7 +1487,9 @@ declare namespace Deno {
}
/**
* This API is a noop in `deno run`...
* This API is useful for testing lint plugins.
*
* It throws an error if it's not used in `deno test` subcommand.
* @category Linter
* @experimental
*/