Helper function that wraps assert.any() to provide better error messages. When assertion fails, it includes the option name in the error message.
(optionName: string, validators: Array<(value: unknown) => boolean>, value: unknown)
| 900 | When assertion fails, it includes the option name in the error message. |
| 901 | */ |
| 902 | function assertAny(optionName: string, validators: Array<(value: unknown) => boolean>, value: unknown): void { |
| 903 | wrapAssertionWithContext(optionName, () => { |
| 904 | assert.any(validators, value); |
| 905 | }); |
| 906 | } |
| 907 | |
| 908 | /** |
| 909 | Helper function that wraps assert.plainObject() to provide better error messages. |
no test coverage detected
searching dependent graphs…