UNPKG

@salesforce/salesforcedx-vscode-test-tools

Version:
38 lines (37 loc) 1.8 kB
import { Duration } from '../core/miscellaneous'; import { ExtensionType, ExtensionActivation, ExtensionConfig } from '../core/types'; import { Editor } from 'vscode-extension-tester'; export declare const extensions: ExtensionType[]; /** * Shows the list of running extensions in VS Code * @returns The editor showing running extensions, or undefined if not found */ export declare function showRunningExtensions(): Promise<Editor | undefined>; /** * Reloads the VS Code window and enables all extensions */ export declare function reloadAndEnableExtensions(): Promise<void>; /** * Gets a list of extensions that need to be verified as active * @param predicate - Optional filter function to apply to the extensions * @returns Array of extensions that should be verified as active */ export declare function getExtensionsToVerifyActive(predicate?: (ext: ExtensionType) => boolean): ExtensionType[]; /** * Verifies that specified extensions are running in VS Code * @param extensions - Array of extensions to verify * @param timeout - Optional timeout (defaults to VERIFY_EXTENSIONS_TIMEOUT) * @returns True if all extensions are activated successfully */ export declare function verifyExtensionsAreRunning(extensions: ExtensionConfig[], timeout?: Duration): Promise<boolean>; /** * Finds and returns information about running extensions * @param extensionIds - Array of extension IDs to look for * @returns Array of extension activation information * @throws If the running extensions editor cannot be found */ export declare function findExtensionsInRunningExtensionsList(extensionIds: string[]): Promise<ExtensionActivation[]>; /** * Checks for uncaught errors in extensions and fails the test if any are found */ export declare function checkForUncaughtErrors(): Promise<void>;