@amiceli/vitest-cucumber
Version:
vitest tools to use Gherkin feature in unit tests
16 lines (15 loc) • 648 B
TypeScript
import { type ArrowFunction, type CallExpression, type SourceFile, SyntaxKind } from 'ts-morph';
export declare class AstUtils {
private callExpressions;
private readonly sourceParent;
private constructor();
static fromSourceFile(sourceFile: SourceFile): AstUtils;
static fromArrowFunction(parent: ArrowFunction): AstUtils;
listDescendantCallExpressions(): this;
matchExpressionName(text: string): this;
matchExpressionArg(argRequired: string): this;
textMatchRegex(regex: RegExp): this;
getAll(): CallExpression[];
getOne(): CallExpression | undefined;
static isString(kind: SyntaxKind): boolean;
}