import { type FileSystem } from './file_system.js'; declare module '@japa/assert' { interface Assert { /** * The file system instance is required by the assertion methods */ fs: FileSystem; /** * Assert file exists at a given path */ fileExists(filePath: string, message?: string): Promise; /** * Assert file does not exists at a given path */ fileNotExists(filePath: string, message?: string): Promise; /** * Assert file contents to equals a string value */ fileEquals(filePath: string, contents: string, message?: string): Promise; /** * Assert file contents to contain a substring or match a regular * expression */ fileContains(filePath: string, substring: string | string[] | RegExp, message?: string): Promise; /** * Assert file contents does not contain the given substrings or * does not match the given regular expression */ fileNotContains(filePath: string, substring: string | string[], message?: string): Promise; /** * Assert file contents to be same as other file's content */ fileSameAs(filePath: string, otherFilePath: string, message?: string): Promise; /** * Assert file to exist and be empty */ fileIsEmpty(filePath: string, message?: string): Promise; /** * Assert file to be not empty */ fileIsNotEmpty(filePath: string, message?: string): Promise; /** * Assert directory exists at a given path */ dirExists(dirPath: string, message?: string): Promise; /** * Assert directory does not exists at a given path */ dirNotExists(dirPath: string, message?: string): Promise; /** * Assert all the mentioned files exists */ hasFiles(filesToExpect: string[], message?: string): Promise; /** * Assert all the mentioned files does not exists */ doesNotHaveFiles(filesToBeMissing: string[], message?: string): Promise; /** * Assert a given directory to have no files */ dirIsEmpty(directoryPath?: string, message?: string): Promise; /** * Assert a given directory to have atleast one file */ dirIsNotEmpty(directoryPath?: string, message?: string): Promise; } }