@case-contract-testing/case
Version:
Next-generation contract testing suite
14 lines (13 loc) • 868 B
TypeScript
import { type ContractDescription, type CaseExample, type MatchContext, AnyMockDescriptorType } from '../entities/types';
import { BaseCaseContract } from './BaseCaseContract';
import type { TestInvoker } from './executeExample/types';
import type { CaseConfig, WriterDependencies } from './types';
export declare class WritingCaseContract extends BaseCaseContract {
private testIndex;
private mutex;
private dependencies;
constructor(description: ContractDescription, dependencies: WriterDependencies, config: CaseConfig);
executeTest<T extends AnyMockDescriptorType, R>({ states, mockDescription, trigger, testResponse, triggers, testErrorResponse, stateHandlers, }: TestInvoker<T, R>, runConfig: CaseConfig): Promise<unknown>;
recordExample(example: CaseExample, currentContext: MatchContext): CaseExample;
endRecord(): Promise<void>;
}