/*! * Copyright (c) Microsoft Corporation and contributors. All rights reserved. * Licensed under the MIT License. */ import type { IMergeTreeOptions } from "../index.js"; import { type PropertySet } from "../properties.js"; import { TestClient } from "./testClient.js"; type ClientMap = Partial>; export declare function createClientsAtInitialState, TClientName extends string = string & keyof TClients>(opts: { initialState: string; options?: IMergeTreeOptions & PropertySet; }, ...clientIds: TClientName[]): Record & { all: TestClient[]; }; export declare class TestClientLogger { private readonly clients; private readonly title?; static toString(clients: readonly TestClient[]): string; private readonly incrementalLog; private readonly paddings; private readonly roundLogLines; private ackedLine; private localLine; private lastDeltaArgs; private readonly disposeCallbacks; /** * Unsubscribes this logger from its clients' events. Consider using this for tests with client lifetime * extending significantly past the logger's. */ dispose(): void; constructor(clients: readonly TestClient[], title?: string | undefined); private addNewLogLine; validate(opts?: { clear?: boolean; baseText?: string; errorPrefix?: string; }): string; static validate(clients: readonly TestClient[], title?: string): string; toString(excludeHeader?: boolean): string; addLogsToError(e: unknown): Error; /** * Get a string representation of the merge-tree state. * * @privateRemarks * This function is a dominating bottleneck in operation runner tests, as they log multiple client states per operation performed. * This takes about 28% of the overall test time, so some inner-loop elements of this favor performance over readability/safety * (e.g. precomputing removed string representations, casting to the more internal segment interfaces to view insertion/removal info * rather than import typeguards, etc.) */ private static getSegString; } export {}; //# sourceMappingURL=testClientLogger.d.ts.map