export type CheckStatus = 'pass' | 'warn' | 'fail'; export interface DoctorCheck { id: string; label: string; status: CheckStatus; detail: string; /** What to do about a warning or failure. */ fix?: string; } export interface DoctorContext { projectDir: string; /** The environment as the project sees it, `.env` loaded. */ env: Record; nodeVersion: string; /** Network and service probes; off in tests that only check the project files. */ probe: boolean; fetch?: typeof fetch; } /** Fills `env` with the variables of the project's `.env` that it does not set already. */ export declare function loadProjectEnv(projectDir: string, env?: Record): void; /** Whether `version` (like `v22.23.1`) satisfies a `>=x.y.z` range, the only form engines use here. */ export declare function satisfiesMinimum(version: string, range: string): boolean; /** Variables `.env.example` lists without a leading `#`: the ones the project requires. */ export declare function requiredVariables(projectDir: string): string[]; /** * The version of `name` the project resolves, `undefined` when it is not * installed. Plug'n'Play installs are read through Yarn's own API, others the * way Node looks packages up: node_modules of the project and every directory * above it, so hoisted packages of a monorepo count. */ export declare function installedVersion(projectDir: string, name: string): string | undefined; /** Host and port of a service URL such as `redis://localhost:6379`, with the scheme's default port. */ export declare function endpointOf(url: string, defaultPort: number): { host: string; port: number; } | undefined; /** Whether a TCP connection to `host:port` opens within `timeoutMs`. */ export declare function canConnect(host: string, port: number, timeoutMs?: number): Promise; /** Everything `cogitator doctor` checks, in the order it shows them. */ export declare function runDoctor(context: DoctorContext): Promise; //# sourceMappingURL=doctor.d.ts.map