@ply-ct/ply
Version:
REST API Automated Testing
51 lines (50 loc) • 1.73 kB
TypeScript
import { Step, StepInstance } from '../flowbee';
import { ExecContext } from './context';
import { RunOptions } from '../options';
import { Values } from '../values';
import { ResultData, Outcome } from '../result';
import { Runtime } from '../runtime';
import { Log } from '../log';
import { ExecResult, StepExec } from './exec';
/**
* Wraps a legacy PlyExecBase implementation
*/
export declare class LegacyExec extends StepExec {
private plyExecBase;
constructor(plyExecBase: PlyExecBase);
run(context: ExecContext): Promise<ExecResult>;
}
/**
* @deprecated Extend StepExec or implement PlyExec directly
*/
export declare abstract class PlyExecBase {
readonly step: Step;
readonly instance: StepInstance;
readonly logger: Log;
static legacy: boolean;
constructor(step: Step, instance: StepInstance, logger: Log);
abstract run(runtime: Runtime, values: Values, runOptions?: RunOptions): Promise<ExecResult>;
protected evaluateToString(expr: string, values: Values, trusted?: boolean): string;
/**
* Returns a substituted attribute value
*/
protected getAttribute(name: string, values: Values, options?: {
trusted?: boolean;
required?: boolean;
}): string | undefined;
isTrustRequired(): boolean;
isExpression(input: string): boolean;
verifyData(runtime: Runtime, data: ResultData, values: Values, runOptions?: RunOptions): Promise<Outcome>;
/**
* Tagged log at info level
*/
logInfo(message: string, obj?: any): void;
/**
* Tagged log at error level
*/
logError(message: string, obj?: any): void;
/**
* Tagged log at debug level
*/
logDebug(message: string, obj?: any): void;
}