/**
 * Copyright Microsoft Corporation. All rights reserved.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
import type { StackFrame } from '@protocol/channels';
export type MatcherAttachment = {
    name: string;
    contentType: string;
    path?: string;
    body?: string | Buffer;
};
export type MatcherResult<E = unknown, A = unknown> = {
    name?: string;
    expected?: E;
    message: () => string;
    pass: boolean;
    actual?: A;
    diff?: string;
    log?: string[];
    timeout?: number;
    ariaSnapshot?: string;
    suggestedRebaseline?: string;
    attachments?: MatcherAttachment[];
    softError?: Error | unknown;
    shouldNotRetryTest?: boolean;
};
export type MatcherResultProperty = Omit<MatcherResult, 'message' | 'name' | 'shouldNotRetryTest'> & {
    name: string;
    message: string;
};
export declare class ExpectError extends Error {
    matcherResult: MatcherResultProperty;
    constructor(matcherResult: MatcherResultProperty, customMessage: string, stackFrames: StackFrame[]);
}
export declare function expectTypes(receiver: any, types: ('APIResponse' | 'Page' | 'Locator')[], matcherName: string): void;
export interface InternalMatcherUtils {
    printDiffOrStringify(expected: unknown, received: unknown, expectedLabel: string, receivedLabel: string, expand: boolean): string;
    printExpected(value: unknown): string;
    printReceived(object: unknown): string;
    DIM_COLOR(text: string): string;
    RECEIVED_COLOR(text: string): string;
    INVERTED_COLOR(text: string): string;
    EXPECTED_COLOR(text: string): string;
}
export declare const printReceivedStringContainExpectedSubstring: (utils: InternalMatcherUtils, received: string, start: number, length: number) => string;
export declare const printReceivedStringContainExpectedResult: (utils: InternalMatcherUtils, received: string, result: RegExpExecArray | null) => string;
type MatcherMessageDetails = {
    promise?: '' | 'rejects' | 'resolves';
    isNot?: boolean;
    receiver?: string;
    matcherName: string;
    expectation: string;
    locator?: string;
    printedExpected?: string;
    printedReceived?: string;
    printedDiff?: string;
    timedOut?: boolean;
    timeout?: number;
    errorMessage?: string;
    log?: string[];
};
export declare function formatMatcherMessage(utils: InternalMatcherUtils, details: MatcherMessageDetails): string;
export declare const callLogText: (utils: InternalMatcherUtils, log: string[] | undefined) => string;
export {};
//# sourceMappingURL=matcherHint.d.ts.map