import type { DOMRect, InstrumentedFunctionResult, CodeLocationDetails, StepError } from '@testim/root-cause-types';
import type { RootCausePage } from './interfaces';
import { ResolvedSettings } from './userSettings/interfaces';
export interface StartTestParams {
    fullName: string;
    fullSuitePath: string;
    description: string;
    projectRoot: string;
    runId: string;
}
export interface AttachParams<TPage extends RootCausePage> {
    startTestParams?: StartTestParams;
    activeFeatures?: ActiveFeatures;
    page: TPage;
}
export declare type ActiveFeatures = ResolvedSettings['features'];
export interface AttachReturn<TPage extends RootCausePage> {
    page: TPage;
    endTest: EndTestFunction;
    persist: (resultLabels: string[]) => Promise<void>;
    pauseStepsRecording(): void;
    resumeStepsRecording(): void;
    reportAssertion: ReportAssertion;
}
export declare type TestEndStatus<T, E> = InstrumentedFunctionResult<T, E>;
export declare type EndTestFunction = (endStatus: TestEndStatus<unknown, unknown>) => Promise<void>;
export interface AssertionReport {
    name?: string;
    screenshot?: string;
    selector?: string;
    fnName?: string;
    text?: string;
    stepError?: StepError;
    stepCodeLocation?: CodeLocationDetails;
    rect?: DOMRect & {
        screenWidth: number;
        screenHeight: number;
        devicePixelRatio: number;
    };
}
export declare type ReportAssertion = (assertion: AssertionReport) => void;
