jest-test-each
Version:
run parametrised tests easily [typesafe] without text tables or arrays of arrays.
13 lines (12 loc) • 496 B
TypeScript
export declare type CodeRename = 'NAME_TOO_LONG' | 'NAME_HAS_FUNCTIONS';
export declare enum CODE_RENAME {
nameTooLong = "NAME_TOO_LONG",
nameHasFunctions = "NAME_HAS_FUNCTIONS"
}
export declare const messageFromRenameCode: (code: CodeRename, maxLength: number) => string;
export declare type NameResult = {
name: string;
code?: CodeRename;
};
export declare const getName: <T>(objs: T[], maxLength: number) => NameResult;
export declare const hasFunction: (obj: any) => boolean;