/** * A WordPress installation, plugin or theme to be loaded into the environment. */ export type WPSource = { /** * The source type. */ type: "local" | "git" | "zip"; /** * The path to the WordPress installation, plugin or theme. */ path: string; /** * The URL to the source download if the source type is not local. */ url: string | null; /** * The git ref for the source if the source type is 'git'. */ ref: string | null; /** * Name that identifies the WordPress installation, plugin or theme. */ basename: string; }; /** * Parses a source string into a source object. * * @param {?string} sourceString The source string. See README.md for documentation on valid source string patterns. * @param {Object} options * @param {string} options.cacheDirectoryPath Path to the work directory located in ~/.wp-env. * * @return {?WPSource} A source object. */ export function parseSourceString(sourceString: string | null, { cacheDirectoryPath }: { cacheDirectoryPath: string; }): WPSource | null; /** * Given a source object, returns a new source object with the testsPath * property set correctly. Only the 'core' source requires a testsPath. * * @param {?WPSource} source A source object. * @param {Object} options * @param {string} options.cacheDirectoryPath Path to the work directory located in ~/.wp-env. * * @return {?WPSource} A source object. */ export function includeTestsPath(source: WPSource | null, { cacheDirectoryPath }: { cacheDirectoryPath: string; }): WPSource | null;