@kkdev92/vscode-ext-kit - v4.1.1
    Preparing search index...

    Interface FakeEditor

    In-memory editor capability for deterministic feature tests. Methods prefixed with _ are test controls, never production port members.

    interface FakeEditor {
        active: ActiveTextEditor | undefined;
        revealed: readonly TextRange[];
        undoStops: readonly NonNullable<
            "none"
            | "both"
            | "before"
            | "after"
            | undefined,
        >[];
        workspaceEdits: readonly RecordedWorkspaceEdit[];
        _close(): void;
        _open(
            options: {
                languageId?: string;
                selections?: readonly TextRange[];
                text: string;
                uri?: string;
            },
        ): void;
        _refuseNextEdit(): void;
        _text(): string;
        applyWorkspaceEdit(
            edits: readonly WorkspaceTextEdit[],
            options?: WorkspaceEditOptions,
        ): Promise<boolean>;
    }

    Hierarchy

    • EditorCapability
      • FakeEditor
    Index
    active: ActiveTextEditor | undefined

    The editor the user is focused on, or undefined when none is.

    revealed: readonly TextRange[]

    Every span revealed, in order.

    undoStops: readonly NonNullable<
        "none"
        | "both"
        | "before"
        | "after"
        | undefined,
    >[]

    The undo boundary each applied batch asked for, in order.

    A grouped edit is ['before', 'none', …, 'after']; a lone one is ['both']. There is no in-memory undo stack to observe, so this is how a test checks that a pipeline is one step rather than several.

    workspaceEdits: readonly RecordedWorkspaceEdit[]

    Every cross-file edit requested, in order.

    • Opens a document, making it the active editor.

      Parameters

      • options: {
            languageId?: string;
            selections?: readonly TextRange[];
            text: string;
            uri?: string;
        }

      Returns void