1- import { SpawnStatus , SudoRequestData , SudoRequestResponseData } from 'codify-schemas' ;
1+ import { SudoRequestData } from 'codify-schemas' ;
22
33import { Plan } from '../../../src/entities/plan.js' ;
44import { ResourceConfig } from '../../../src/entities/resource-config.js' ;
55import { ResourceInfo } from '../../../src/entities/resource-info.js' ;
6+ import { FileModificationResult } from '../../../src/generators/index.js' ;
67import { ImportResult } from '../../../src/orchestrators/import.js' ;
78import { prettyFormatPlan } from '../../../src/ui/plan-pretty-printer.js' ;
89import { PromptType , Reporter } from '../../../src/ui/reporters/reporter.js' ;
9- import { FileModificationResult } from '../../../src/utils/file-modification-calculator.js' ;
1010
1111export interface MockReporterConfig {
1212 validatePlan ?: ( plan : Plan ) => Promise < void > | void ;
@@ -15,7 +15,7 @@ export interface MockReporterConfig {
1515 promptConfirmation ?: ( ) => boolean ;
1616 promptOptions ?: ( message : string , options : string [ ] ) => number ;
1717 promptUserForValues ?: ( resourceInfo : ResourceInfo [ ] ) => Promise < ResourceConfig [ ] > | ResourceConfig [ ] ;
18- promptInput ?: ( prompt : string , error ?: string | undefined , validation ?: ( ( ) => Promise < boolean > ) | undefined , autoComplete ?: ( ( input : string ) => string [ ] ) | undefined ) => Promise < string >
18+ promptInput ?: ( prompt : string , error ?: string | undefined ) => Promise < string >
1919 promptInitResultSelection ?: ( availableTypes : string [ ] ) => Promise < string [ ] > | string [ ] ;
2020 hide ?: ( ) => void ;
2121 displayImportResult ?: ( importResult : ImportResult , showConfigs : boolean ) => Promise < void > | void ;
@@ -48,8 +48,8 @@ export class MockReporter implements Reporter {
4848 return ( await this . config ?. promptInitResultSelection ?.( availableTypes ) ) ?? [ ] ;
4949 }
5050
51- async promptInput ( prompt : string , error ?: string | undefined , validation ?: ( ( ) => Promise < boolean > ) | undefined , autoComplete ?: ( ( input : string ) => string [ ] ) | undefined ) : Promise < string > {
52- return ( await this . config ?. promptInput ?.( prompt , error , validation ) ) ?? '' ;
51+ async promptInput ( prompt : string , error ?: string | undefined ) : Promise < string > {
52+ return ( await this . config ?. promptInput ?.( prompt , error ) ) ?? '' ;
5353 }
5454
5555 async promptPressKeyToContinue ( message ?: string | undefined ) : Promise < void > { }
0 commit comments