1 |
|
2 | import execa from 'execa';
|
3 | import { ArgList, Arguments, Argv } from '@boost/args';
|
4 | import { Path } from '@boost/common';
|
5 | import { mockDebugger } from '@boost/debug/test';
|
6 | import { ConfigContext, ConfigFile, Context, Driver, DriverContext, DriverContextOptions, DriverMetadata, ScaffoldContext, ScaffoldContextOptions, Script, ScriptContext, ScriptContextOptions, Tool } from '.';
|
7 | export { mockDebugger };
|
8 | export declare class TestDriver<O extends object = {}> extends Driver<O> {
|
9 | readonly name = "test-driver";
|
10 | }
|
11 | export declare class TestScript<O extends object = {}> extends Script<O> {
|
12 | readonly name = "test-script";
|
13 | execute(): any;
|
14 | }
|
15 | export declare function mockConsole<K extends keyof Console>(name: K): jest.SpyInstance;
|
16 | export declare function mockToolConfig(): ConfigFile;
|
17 | export declare function mockTool(argv?: Argv): Tool;
|
18 | export declare function mockDriver<C extends object = {}>(name: string, tool?: Tool | null, metadata?: Partial<DriverMetadata>): Driver<C>;
|
19 | export declare function mockScript(name: string, tool?: Tool | null): Script<{}>;
|
20 | export declare function stubArgs<T extends object>(options: T, params?: ArgList): Arguments<T>;
|
21 | export declare function stubConfigArgs(): Arguments<{}>;
|
22 | export declare function stubDriverArgs(fields?: Partial<DriverContextOptions>): Arguments<DriverContextOptions>;
|
23 | export declare function stubScaffoldArgs(fields?: Partial<ScaffoldContextOptions>): Arguments<ScaffoldContextOptions>;
|
24 | export declare function stubScriptArgs(fields?: Partial<ScriptContextOptions>): Arguments<ScriptContextOptions>;
|
25 | export declare function applyContext<T extends Context>(context: T): T;
|
26 | export declare function stubConfigContext(): ConfigContext;
|
27 | export declare function stubDriverContext(driver?: Driver): DriverContext;
|
28 | export declare function stubScriptContext(script?: Script): ScriptContext;
|
29 | export declare function stubScaffoldContext(generator?: string, action?: string, name?: string): ScaffoldContext;
|
30 | export declare function prependRoot(part: string): Path;
|
31 | export declare function getRoot(): Path;
|
32 | export declare function stubExecResult(fields?: Partial<execa.ExecaReturnValue>): execa.ExecaReturnValue;
|
33 |
|
\ | No newline at end of file |