export { } import { type ConfigData } from "./index" import { type Message } from "./index" import "vitest"; declare module "vitest" { interface Assertion { /** * @since 8.5.0 */ toBeValid(): Promise; /** * @since 8.5.0 */ toBeInvalid(): Promise; /** * @since 8.5.0 */ toHaveError(error: Partial): T; /** * @since 8.5.0 */ toHaveError(ruleId: string, message: string, context?: unknown): T; /** * @since 8.5.0 */ toHaveErrors(errors: Array<[string, string] | Record>): T; /** * Validate string or HTMLElement. * * Test passes if result is valid. * * @param config - Optional HTML-Validate configuration object. * @param filename - Optional filename used when matching transformer and * loading configuration. * * @since 8.5.0 */ toHTMLValidate(filename?: string): Promise; toHTMLValidate(config: ConfigData, filename?: string): Promise; toHTMLValidate(error: Partial, filename?: string): Promise; toHTMLValidate(error: Partial, config: ConfigData, filename?: string): Promise; /** * Writes out the given [[Report]] using codeframe formatter and compares * with snapshot. * * * Requires Vitest v4.1.3 or later. * * @since 11.2.0 */ toMatchCodeframe(hint?: string): Promise; /** * Writes out the given [[Report]] using codeframe formatter and compares * with inline snapshot. * * Requires Vitest v4.1.3 or later. * * @since 11.2.0 */ toMatchInlineCodeframe(snapshot?: string): Promise; } interface Matchers { /** * @since 8.5.0 */ toBeValid(): Promise; /** * @since 8.5.0 */ toBeInvalid(): Promise; /** * @since 8.5.0 */ toHaveError(error: Partial): T; /** * @since 8.5.0 */ toHaveError(ruleId: string, message: string, context?: unknown): T; /** * @since 8.5.0 */ toHaveErrors(errors: Array<[string, string] | Record>): T; /** * Validate string or HTMLElement. * * Test passes if result is valid. * * @param config - Optional HTML-Validate configuration object. * @param filename - Optional filename used when matching transformer and * loading configuration. * * @since 8.5.0 */ toHTMLValidate(filename?: string): Promise; toHTMLValidate(config: ConfigData, filename?: string): Promise; toHTMLValidate(error: Partial, filename?: string): Promise; toHTMLValidate(error: Partial, config: ConfigData, filename?: string): Promise; /** * Writes out the given [[Report]] using codeframe formatter and compares * with snapshot. * * * Requires Vitest v4.1.3 or later. * * @since 11.2.0 */ toMatchCodeframe(hint?: string): Promise; /** * Writes out the given [[Report]] using codeframe formatter and compares * with inline snapshot. * * Requires Vitest v4.1.3 or later. * * @since 11.2.0 */ toMatchInlineCodeframe(snapshot?: string): Promise; } }