@n1k1t/mock-server
Version:
The ultimate toolkit to intercept, transform, and simulate HTTP/WS traffic with type-safe expectations
23 lines • 1.28 kB
TypeScript
import { ExpectationOperator } from '../models/operator';
import { TFunction } from '../../../types';
import { CompileExpectationOperatorValue, CompileExpectationOperatorValueWithPredicate, IExpectationSchemaContext, IExpectationExecUtils, TExpectationOperatorLocation, IExpectationMeta } from '../types';
export default class SetExpectationOperator<TContext extends IExpectationSchemaContext, TLocation extends TExpectationOperatorLocation = TExpectationOperatorLocation, TValue = void> extends ExpectationOperator<TContext, {
[K in TLocation]: {
$location: K;
$value?: CompileExpectationOperatorValueWithPredicate<TContext, K, TValue>;
$exec?: string | TFunction<CompileExpectationOperatorValueWithPredicate<TContext, K, TValue>, [
CompileExpectationOperatorValue<TContext, K, TValue>,
IExpectationExecUtils<TContext>
]>;
$path?: string;
$jsonPath?: string;
};
}[TLocation]> {
compiled: {
exec?: TFunction<Promise<unknown>, [import("../types").IExpectationExecMode, TContext, ...unknown[]]> | undefined;
};
get tags(): IExpectationMeta['tags'];
match(): Promise<boolean>;
manipulate<T extends TContext>(context: T): Promise<T>;
}
//# sourceMappingURL=set.operator.d.ts.map