## Beta API Report File for "@fluidframework/test-runtime-utils"

> Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/).

```ts

// @beta @legacy (undocumented)
export interface IInternalMockRuntimeMessage {
    // (undocumented)
    content: any;
    // (undocumented)
    localOpMetadata?: unknown;
    // (undocumented)
    referenceSequenceNumber?: number;
}

// @beta @legacy
export interface IMockContainerRuntimeOptions {
    readonly enableGroupedBatching?: boolean;
    readonly flushMode?: FlushMode;
}

// @beta @legacy (undocumented)
export interface IMockContainerRuntimePendingMessage {
    // (undocumented)
    clientSequenceNumber: number;
    // (undocumented)
    content: any;
    // (undocumented)
    localOpMetadata: unknown;
    // (undocumented)
    referenceSequenceNumber: number;
}

// @beta @legacy (undocumented)
export class MockAudience extends TypedEventEmitter<IAudienceEvents> implements IAudienceOwner {
    constructor();
    // (undocumented)
    addMember(clientId: string, member: IClient): void;
    // (undocumented)
    getMember(clientId: string): IClient | undefined;
    // (undocumented)
    getMembers(): Map<string, IClient>;
    // (undocumented)
    getSelf(): ISelf | undefined;
    // (undocumented)
    removeMember(clientId: string): boolean;
    // (undocumented)
    setCurrentClientId(clientId: string): void;
}

// @beta @legacy
export class MockContainerRuntime extends TypedEventEmitter<IContainerRuntimeEvents> {
    constructor(dataStoreRuntime: MockFluidDataStoreRuntime, factory: MockContainerRuntimeFactory, mockContainerRuntimeOptions?: IMockContainerRuntimeOptions, overrides?: {
        minimumSequenceNumber?: number | undefined;
    } | undefined);
    // (undocumented)
    protected addPendingMessage(content: any, localOpMetadata: unknown, clientSequenceNumber: number): void;
    // (undocumented)
    clientId: string;
    // @deprecated
    createDeltaConnection(): MockDeltaConnection;
    // (undocumented)
    protected readonly dataStoreRuntime: MockFluidDataStoreRuntime;
    // @deprecated (undocumented)
    protected readonly deltaConnections: MockDeltaConnection[];
    // (undocumented)
    readonly deltaManager: MockDeltaManager;
    // (undocumented)
    dirty(): void;
    // (undocumented)
    protected readonly factory: MockContainerRuntimeFactory;
    flush(): void;
    flushSomeMessages(numMessages: number): void;
    // (undocumented)
    get isDirty(): boolean;
    protected maybeProcessIdAllocationMessage(message: ISequencedDocumentMessage): boolean;
    // (undocumented)
    protected readonly outbox: IInternalMockRuntimeMessage[];
    // (undocumented)
    protected readonly overrides?: {
        minimumSequenceNumber?: number | undefined;
    } | undefined;
    // (undocumented)
    protected readonly pendingMessages: IMockContainerRuntimePendingMessage[];
    // (undocumented)
    process(message: ISequencedDocumentMessage): void;
    // (undocumented)
    protected processInternal(message: ISequencedDocumentMessage): [boolean, unknown];
    rebase(): void;
    // (undocumented)
    resolveHandle(handle: IFluidHandle): Promise<IResponse>;
    // (undocumented)
    protected reSubmitMessages(messagesToResubmit: {
        content: any;
        localOpMetadata?: unknown;
    }[]): void;
    rollback?(): void;
    protected readonly runtimeOptions: Required<IMockContainerRuntimeOptions>;
    // (undocumented)
    runWithManualFlush(act: () => void | Promise<void>): Promise<void>;
    // (undocumented)
    submit(messageContent: any, localOpMetadata?: unknown): number;
}

// @beta @legacy
export class MockContainerRuntimeFactory {
    constructor(mockContainerRuntimeOptions?: IMockContainerRuntimeOptions);
    // (undocumented)
    createContainerRuntime(dataStoreRuntime: MockFluidDataStoreRuntime): MockContainerRuntime;
    // (undocumented)
    protected getFirstMessageToProcess(): ISequencedDocumentMessage;
    getMinSeq(): number;
    // (undocumented)
    protected lastProcessedMessage: ISequencedDocumentMessage | undefined;
    protected messages: ISequencedDocumentMessage[];
    // (undocumented)
    minSeq: Map<string, number>;
    // (undocumented)
    get outstandingMessageCount(): number;
    processAllMessages(): void;
    processOneMessage(): void;
    processSomeMessages(count: number): void;
    // (undocumented)
    pushMessage(msg: Partial<ISequencedDocumentMessage>): void;
    // (undocumented)
    readonly quorum: MockQuorumClients;
    // (undocumented)
    removeContainerRuntime(containerRuntime: MockContainerRuntime): void;
    protected readonly runtimeOptions: Required<IMockContainerRuntimeOptions>;
    // (undocumented)
    protected readonly runtimes: Set<MockContainerRuntime>;
    // (undocumented)
    sequenceNumber: number;
}

// @beta @legacy
export class MockContainerRuntimeFactoryForReconnection extends MockContainerRuntimeFactory {
    // (undocumented)
    clearOutstandingClientMessages(clientId: string): void;
    // (undocumented)
    createContainerRuntime(dataStoreRuntime: MockFluidDataStoreRuntime, overrides?: {
        minimumSequenceNumber?: number;
        trackRemoteOps?: boolean;
    }): MockContainerRuntimeForReconnection;
}

// @beta @legacy
export class MockContainerRuntimeForReconnection extends MockContainerRuntime {
    constructor(dataStoreRuntime: MockFluidDataStoreRuntime, factory: MockContainerRuntimeFactoryForReconnection, runtimeOptions?: IMockContainerRuntimeOptions, overrides?: {
        minimumSequenceNumber?: number;
        trackRemoteOps?: boolean;
    });
    get connected(): boolean;
    set connected(connected: boolean);
    // (undocumented)
    protected readonly factory: MockContainerRuntimeFactoryForReconnection;
    // (undocumented)
    flush(): void;
    // (undocumented)
    initializeWithStashedOps(fromContainerRuntime: MockContainerRuntimeForReconnection): Promise<void>;
    protected readonly pendingRemoteMessages: ISequencedDocumentMessage[];
    // (undocumented)
    process(message: ISequencedDocumentMessage): void;
    // (undocumented)
    protected readonly processedOps?: ISequencedDocumentMessage[];
    // (undocumented)
    protected processPendingMessages(pendingMessages: ISequencedDocumentMessage[]): void;
    // (undocumented)
    protected setConnectedState(connected: boolean): void;
    // (undocumented)
    submit(messageContent: any, localOpMetadata: unknown): number;
}

// @beta @legacy
export class MockDeltaConnection implements IDeltaConnection {
    constructor(submitFn: (messageContent: any, localOpMetadata: unknown) => number, dirtyFn: () => void);
    // (undocumented)
    applyStashedOp(content: any): unknown;
    // (undocumented)
    attach(handler: IDeltaHandler): void;
    // (undocumented)
    get connected(): boolean;
    // (undocumented)
    dirty(): void;
    // (undocumented)
    handler: IDeltaHandler | undefined;
    // (undocumented)
    processMessages(messageCollection: IRuntimeMessageCollection): void;
    // (undocumented)
    reSubmit(content: any, localOpMetadata: unknown, squash: boolean): void;
    // (undocumented)
    rollback?(message: any, localOpMetadata: unknown): void;
    // (undocumented)
    setConnectionState(connected: boolean): void;
    // (undocumented)
    submit(messageContent: any, localOpMetadata: unknown): number;
}

// @beta @legacy
export class MockDeltaManager extends TypedEventEmitter<IDeltaManagerEvents> implements IDeltaManager<ISequencedDocumentMessage, IDocumentMessage> {
    constructor(getClientId?: (() => string | undefined) | undefined);
    // (undocumented)
    active: boolean;
    // (undocumented)
    readonly clientDetails: IClientDetails;
    // (undocumented)
    clientSequenceNumber: number;
    // (undocumented)
    readonly clientType: string;
    // (undocumented)
    close(): void;
    // (undocumented)
    dispose(): void;
    // (undocumented)
    get disposed(): any;
    // (undocumented)
    flush(): void;
    // (undocumented)
    hasCheckpointSequenceNumber: boolean;
    // (undocumented)
    get IDeltaSender(): this;
    // (undocumented)
    get inbound(): MockDeltaQueue<ISequencedDocumentMessage>;
    // (undocumented)
    get inboundSignal(): MockDeltaQueue<ISignalMessage>;
    // (undocumented)
    initialSequenceNumber: number;
    // (undocumented)
    readonly lastKnownSeqNumber = 0;
    // (undocumented)
    lastMessage: ISequencedDocumentMessage | undefined;
    // (undocumented)
    lastSequenceNumber: number;
    // (undocumented)
    readonly maxMessageSize: number;
    // (undocumented)
    minimumSequenceNumber: number;
    // (undocumented)
    get outbound(): MockDeltaQueue<IDocumentMessage[]>;
    // (undocumented)
    process(message: ISequencedDocumentMessage): void;
    // (undocumented)
    readOnlyInfo: ReadOnlyInfo;
    // (undocumented)
    get serviceConfiguration(): IClientConfiguration;
    // (undocumented)
    submit(type: MessageType, contents: any, batch: boolean | undefined, localOpMetadata: any): number;
    // (undocumented)
    submitSignal(content: any): void;
    // (undocumented)
    get version(): string;
}

// @beta @legacy
export class MockDeltaQueue<T> extends EventEmitter implements IDeltaQueue<T> {
    constructor();
    // (undocumented)
    dispose(): void;
    // (undocumented)
    get disposed(): any;
    // (undocumented)
    get idle(): boolean;
    // (undocumented)
    get length(): number;
    // (undocumented)
    pause(): Promise<void>;
    // (undocumented)
    protected pauseCount: number;
    // (undocumented)
    get paused(): boolean;
    // (undocumented)
    peek(): T | undefined;
    // (undocumented)
    pop(): T | undefined;
    // (undocumented)
    protected process(): void;
    // (undocumented)
    processCallback: (el: T) => void;
    // (undocumented)
    push(el: T): void;
    // (undocumented)
    protected readonly queue: T[];
    // (undocumented)
    resume(): void;
    // (undocumented)
    toArray(): T[];
    // (undocumented)
    waitTillProcessingDone(): Promise<{
        count: number;
        duration: number;
    }>;
}

// @beta @legacy (undocumented)
export class MockFluidDataStoreContext implements IFluidDataStoreContext {
    constructor(id?: string, existing?: boolean, baseLogger?: ITelemetryLoggerExt, interactive?: boolean);
    // (undocumented)
    addedGCOutboundRoute(fromPath: string, toPath: string, messageTimestampMs?: number): void;
    attachState: AttachState;
    // (undocumented)
    readonly baseLogger: ITelemetryLoggerExt;
    // (undocumented)
    baseSnapshot: ISnapshotTree | undefined;
    // (undocumented)
    clientDetails: IClientDetails;
    // (undocumented)
    clientId: string | undefined;
    // (undocumented)
    connected: boolean;
    // (undocumented)
    containerRuntime: IContainerRuntimeBase;
    // @deprecated (undocumented)
    createProps?: any;
    // (undocumented)
    deleteChildSummarizerNode(id: string): void;
    // (undocumented)
    deltaManager: IDeltaManager<ISequencedDocumentMessage, IDocumentMessage>;
    // (undocumented)
    readonly existing: boolean;
    // (undocumented)
    readonly gcThrowOnTombstoneUsage = false;
    // (undocumented)
    readonly gcTombstoneEnforcementAllowed = false;
    // (undocumented)
    getAbsoluteUrl(relativeUrl: string): Promise<string | undefined>;
    // (undocumented)
    getAudience(): IAudience;
    // (undocumented)
    getBaseGCDetails(): Promise<IGarbageCollectionDetailsBase>;
    // (undocumented)
    getCreateChildSummarizerNodeFn(id: string, createParam: CreateChildSummarizerNodeParam): CreateChildSummarizerNodeFn;
    // (undocumented)
    getQuorum(): IQuorumClients;
    // (undocumented)
    readonly id: string;
    // (undocumented)
    idCompressor: IIdCompressor;
    // (undocumented)
    IFluidDataStoreRegistry: IFluidDataStoreRegistry;
    // (undocumented)
    IFluidHandleContext: IFluidHandleContext;
    // (undocumented)
    ILayerCompatDetails?: unknown;
    // (undocumented)
    isLocalDataStore: boolean;
    // (undocumented)
    makeLocallyVisible(): void;
    minVersionForCollab: OldestSupportedClientVersion;
    // (undocumented)
    off(event: string | symbol, listener: (...args: any[]) => void): this;
    // (undocumented)
    on(event: string | symbol, listener: (...args: any[]) => void): this;
    // (undocumented)
    once(event: string | symbol, listener: (...args: any[]) => void): this;
    // (undocumented)
    options: Record<string | number, any>;
    // (undocumented)
    packagePath: readonly string[];
    // (undocumented)
    readonly: boolean;
    // (undocumented)
    scope: FluidObject;
    // (undocumented)
    setChannelDirty(address: string): void;
    // (undocumented)
    storage: IRuntimeStorageService;
    // (undocumented)
    submitMessage(): void;
    // (undocumented)
    submitSignal(): void;
    // (undocumented)
    uploadBlob(blob: ArrayBufferLike): Promise<IFluidHandleInternal<ArrayBufferLike>>;
}

// @beta @sealed @legacy
export class MockFluidDataStoreRuntime extends EventEmitter implements IFluidDataStoreRuntime, IFluidDataStoreChannel, IFluidHandleContext {
    constructor(overrides?: {
        clientId?: string;
        entryPoint?: IFluidHandle<FluidObject>;
        id?: string;
        logger?: ITelemetryBaseLogger;
        idCompressor?: IIdCompressor;
        attachState?: AttachState;
        registry?: readonly IChannelFactory[];
        minVersionForCollab?: OldestSupportedClientVersion;
        inStagingMode?: boolean;
        isDirty?: boolean;
    });
    // (undocumented)
    get absolutePath(): string;
    // (undocumented)
    addChannel(channel: IChannel): void;
    // (undocumented)
    applyStashedOp(content: any): Promise<unknown>;
    // (undocumented)
    attachGraph(): void;
    // (undocumented)
    get attachState(): AttachState;
    // (undocumented)
    bind(handle: IFluidHandle): void;
    // (undocumented)
    bindChannel(channel: IChannel): void;
    // (undocumented)
    get channelsRoutingContext(): IFluidHandleContext;
    // (undocumented)
    clientId: string;
    // (undocumented)
    close(): Promise<void>;
    // (undocumented)
    readonly connected = true;
    // (undocumented)
    containerRuntime?: MockContainerRuntime;
    // (undocumented)
    createChannel(id: string | undefined, type: string): IChannel;
    // (undocumented)
    createDeltaConnection(): MockDeltaConnection;
    // (undocumented)
    get deltaManager(): IDeltaManagerErased;
    // (undocumented)
    deltaManagerInternal: MockDeltaManager;
    // (undocumented)
    dispose(): void;
    // (undocumented)
    get disposed(): boolean;
    // (undocumented)
    readonly documentId: string;
    // (undocumented)
    readonly entryPoint: IFluidHandleInternal<FluidObject>;
    // (undocumented)
    readonly existing: boolean;
    // (undocumented)
    getAttachGCData(telemetryContext?: ITelemetryContext | undefined): IGarbageCollectionData;
    // (undocumented)
    getAttachSnapshot(): ITreeEntry[];
    // (undocumented)
    getAttachSummary(): ISummaryTreeWithStats;
    // (undocumented)
    getAudience(): IAudience;
    // (undocumented)
    getBlob(blobId: string): Promise<any>;
    // (undocumented)
    getChannel(id: string): Promise<IChannel>;
    // (undocumented)
    getGCData(): Promise<IGarbageCollectionData>;
    // (undocumented)
    getQuorum(): IQuorumClients;
    // (undocumented)
    readonly id: string;
    // (undocumented)
    idCompressor: IIdCompressor | undefined;
    // (undocumented)
    get IFluidHandleContext(): IFluidHandleContext;
    // (undocumented)
    ILayerCompatDetails?: unknown;
    // (undocumented)
    readonly inStagingMode: boolean;
    // (undocumented)
    get isAttached(): boolean;
    // (undocumented)
    readonly isDirty: boolean;
    // (undocumented)
    readonly isReadOnly: () => boolean;
    // (undocumented)
    readonly loader: ILoader;
    // @deprecated
    get local(): boolean;
    set local(local: boolean);
    // (undocumented)
    readonly logger: ITelemetryBaseLogger;
    // (undocumented)
    makeVisibleAndAttachGraph(): void;
    // (undocumented)
    readonly minVersionForCollab: OldestSupportedClientVersion;
    // (undocumented)
    notifyReadOnlyState(readonly: boolean): void;
    // (undocumented)
    get objectsRoutingContext(): IFluidHandleContext;
    // (undocumented)
    options: Record<string | number, any>;
    // (undocumented)
    readonly path = "";
    // (undocumented)
    processMessages(messageCollection: IRuntimeMessageCollection): void;
    // (undocumented)
    processSignal(message: any, local: boolean): void;
    // (undocumented)
    quorum: MockQuorumClients;
    // (undocumented)
    request(request: IRequest): Promise<IResponse>;
    // (undocumented)
    requestDataStore(request: IRequest): Promise<IResponse>;
    // (undocumented)
    resolveHandle(request: IRequest): Promise<IResponse>;
    // (undocumented)
    reSubmit(content: any, localOpMetadata: unknown, squash: boolean): void;
    // (undocumented)
    rollback?(message: any, localOpMetadata: unknown): void;
    // (undocumented)
    get rootRoutingContext(): IFluidHandleContext;
    // (undocumented)
    save(message: string): void;
    // (undocumented)
    setAttachState(attachState: AttachState.Attaching | AttachState.Attached): void;
    // (undocumented)
    setConnectionState(connected: boolean, clientId?: string): void;
    // (undocumented)
    submitSignal: IFluidDataStoreRuntime["submitSignal"];
    // (undocumented)
    summarize(fullTree?: boolean, trackState?: boolean): Promise<ISummaryTreeWithStats>;
    // (undocumented)
    updateMinSequenceNumber(value: number): void;
    // (undocumented)
    updateUsedRoutes(usedRoutes: string[]): void;
    // (undocumented)
    uploadBlob(blob: ArrayBufferLike): Promise<IFluidHandle<ArrayBufferLike>>;
    // (undocumented)
    get visibilityState(): VisibilityState;
    // (undocumented)
    waitAttached(): Promise<void>;
}

// @beta @legacy
export class MockHandle<T> extends FluidHandleBase<T> {
    constructor(value: T, path?: string, absolutePath?: string);
    // (undocumented)
    readonly absolutePath: string;
    // (undocumented)
    attachGraph(): void;
    // (undocumented)
    get(): Promise<T>;
    // (undocumented)
    get isAttached(): boolean;
    // (undocumented)
    readonly path: string;
    // (undocumented)
    protected readonly value: T;
}

// @beta @legacy
export class MockObjectStorageService implements IChannelStorageService {
    constructor(contents: {
        [key: string]: string;
    });
    // (undocumented)
    contains(path: string): Promise<boolean>;
    // (undocumented)
    getSnapshotTree(): ISnapshotTree;
    // (undocumented)
    list(path: string): Promise<string[]>;
    // (undocumented)
    readBlob(path: string): Promise<ArrayBufferLike>;
}

// @beta @legacy (undocumented)
export class MockQuorumClients implements IQuorumClients, EventEmitter {
    constructor(...members: [string, Partial<ISequencedClient>][]);
    // (undocumented)
    addListener(event: string | number, listener: (...args: any[]) => void): this;
    // (undocumented)
    addMember(id: string, client: Partial<ISequencedClient>): void;
    // (undocumented)
    dispose(): void;
    // (undocumented)
    disposed: boolean;
    // (undocumented)
    emit(event: string | number, ...args: any[]): boolean;
    // (undocumented)
    eventNames(): (string | number)[];
    // (undocumented)
    getMaxListeners(): number;
    // (undocumented)
    getMember(clientId: string): ISequencedClient | undefined;
    // (undocumented)
    getMembers(): Map<string, ISequencedClient>;
    // (undocumented)
    listenerCount(type: string | number): number;
    // (undocumented)
    listeners(event: string | number): ReturnType<EventEmitter["listeners"]>;
    // (undocumented)
    off(event: string | number, listener: (...args: any[]) => void): this;
    // (undocumented)
    on(event: string | number, listener: (...args: any[]) => void): this;
    // (undocumented)
    once(event: string | number, listener: (...args: any[]) => void): this;
    // (undocumented)
    prependListener(event: string | number, listener: (...args: any[]) => void): this;
    // (undocumented)
    prependOnceListener(event: string | number, listener: (...args: any[]) => void): this;
    // (undocumented)
    rawListeners(event: string | number): ReturnType<EventEmitter["rawListeners"]>;
    // (undocumented)
    removeAllListeners(event?: string | number | undefined): this;
    // (undocumented)
    removeListener(event: string | number, listener: (...args: any[]) => void): this;
    // (undocumented)
    removeMember(id: string): void;
    // (undocumented)
    setMaxListeners(n: number): this;
}

// @beta @legacy
export class MockSharedObjectServices implements IChannelServices {
    constructor(contents: {
        [key: string]: string;
    });
    // (undocumented)
    static createFromSummary(summaryTree: ISummaryTree): MockSharedObjectServices;
    // (undocumented)
    deltaConnection: IDeltaConnection;
    // (undocumented)
    objectStorage: MockObjectStorageService;
}

// @beta @legacy
export class MockStorage implements IChannelStorageService {
    constructor(tree?: ITree | undefined);
    // (undocumented)
    contains(path: string): Promise<boolean>;
    // (undocumented)
    static createFromSummary(summaryTree: ISummaryTree): MockStorage;
    // (undocumented)
    getSnapshotTree(): ISnapshotTree | undefined;
    // (undocumented)
    list(path: string): Promise<string[]>;
    // (undocumented)
    readBlob(path: string): Promise<ArrayBufferLike>;
    // (undocumented)
    protected tree?: ITree | undefined;
}

// (No @packageDocumentation comment for this package)

```
